SID-02039: Problem with regex
| Status: |
Answered |
TWiki version: |
|
Perl version: |
|
| Category: |
|
Server OS: |
|
Last update: |
10 years ago |
Each time I try to view the
SandBox web page:
UniandesVBFPhenomenologyProject, the following error appears:
TWiki detected an internal error - please check your TWiki logs and webserver logs for more information.
Nested quantifiers in regex; marked by <-- HERE in m/\bTwistyContrib_1_2_C++ <-- HERE Program=(.+?)\b/
How can I check my Twiki logs or modify again the twiki?
--
Andres Florez - 2015-03-20
Discussion and Answer
Hello Andres,
I "fixed" it in
TWiki:Sandbox.UniandesVBFPhenomenologyProject
, but I'd rather call this a workaround.
From the error message I
guessed that the '++' is a problem, and by simply removing it the page shows ok.
A '+' is a quantifier in Perl regexes, and two of them confuse Perl. Your web server's error log might show the module and line where the error occurs.
Old:
%TWISTY{id="1_2_C++Program"; ...
New:
%;TWISTY{id="1_2_CProgram" ...
So, if you can get rid of the '++' easily, that could be good enough.
However, I am far from understanding the problem fully. Most likely it is a bug. A very interesting symptom (do you experience this, too?): If I log in, the error disappears - if I log out again, the error reappears. Unfortunately I could not reproduce the error in the current development version (SVN TWiki), and I am not familiar with Twisty code. So, without a hint where this happens I seem to be lost.
--
Harald Jörg - 2015-03-20
Closing this question after more than 30 days of inactivity. Feel free to reopen if needed. Consider engaging one of the
TWiki consultants if you need timely help. We invite you to
get involved with the community, it is more likely you get community support if you support the open source project!
--
Peter Thoeny - 2015-12-03
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.