Question
I'm getting the error:
Use of uninitialized value in substitution (s///) at (eval 41) line 23
when I click 'next' from the config screen. This prevents any changes to config, including install of plugins etc. Any solutions/ workarounds appreciated.
Environment
--
TWikiGuest - 04 Apr 2008
Answer
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.
I am also getting exactly the same error at the same location (when clicking on next in the configure and also when installing any new plugins) , earlier it use to work fine. I have the following error in my apache log
Use of uninitialized value in concatenation (.) or string at /home/tree/public_html/safa/lib/TWiki/Plugins/ExcelImportExportPlugin/Import.pm line 53.
--
MubashirAnsari - 05 Apr 2008
Are you guys on cpanel servers btw?
--
BrianCarpenter - 05 Apr 2008
what do mean by cpanel servers?
--
MubashirAnsari - 05 Apr 2008
I don't know what it means either- so I guess not!
--
TWikiGuest - 06 Apr 2008
cpanel is:
http://en.wikipedia.org/wiki/CPanel
(it looks like:

) and is used on linux hosters on managed accounts.
--
ColasNahaboo - 06 Apr 2008
FYI I've pinned this down to a POST error in CGI.pm, around line 3390 with the following content:
# See RFC 1867, 2183, 2045
# NB: File content will be loaded into memory should
# content-disposition parsing fail.
my ($filename) = $header{'Content-Disposition'}
=~/ filename=(("[^"]*")|([a-z\d!\#'\*\+,\.^_\`\{\}\|\~]*))/i;
$filename =~ s/^"([^"]*)"$/$1/;
# Test for Opera's multiple upload feature
my($multipart) = ( defined( $header{'Content-Type'} ) &&
$header{'Content-Type'} =~ /multipart\/mixed/ ) ?
-
- : 0;
--
TWikiGuest - 07 Apr 2008
Just have to work out what it is from twiki that's causing the problem....
--
TWikiGuest - 07 Apr 2008
POSSIBLE FIX: Add the code "if (defined $filename);" to line 3390 of CGI.pm so that it now reads "$filename =~ s/^"([^"]*)"$/$1/;". I think this might just be a case of error paranoia in the Twiki configure script that makes it fatal unnecessarily to browser. I'm still having trouble with installing extensions, but this seems to be a permissions issue....
--
TWikiGuest - 07 Apr 2008
Oops- forgot to add the 'if' on the end of that- but you catch my meaning.
--
TWikiGuest - 07 Apr 2008
Hi, I'm getting the exact same error as the op with configure
--
AndrewCrystall - 09 Apr 2008
Hello. Same error. I am using shared hosting with Cpanel. Uploaded the gpz file and untarred the file. index.html works fine. I had to add .pl to the end of configure to get it to run. After filling out the information and clicking next, I get this error. Thanks for any help!
--
TWikiGuest - 11 Apr 2008
Comment the line $SIG{'__WARN__'} = sub { die
@_
}; in configure script ( Warnings are fatal )
--
MikePort - 17 Apr 2008
I have a workaround, not a fix. You can edit the configuration file (I, too, had to add .pl to the script. I did this to all the script files. Don't know if this was needed...
The workaround is this: Open configuration and edit the shebang line at the top, this is the first line that begins with #! and ends with -w
Change the -w to -s. This suppressed the warning, and the script runs and the installation continues. Now, I have NOT finished my install. This may not work or it may mask other problems. But, at least, you can work on your install. Robb
--
RobbLightfoot - 02 May 2008
Well, the script installed Twiki. Here's what I get when I try to go to the home page. (I've installed this on a hosted, cpanel server.)
Not Found
The requested URL /bin/view/ was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an
ErrorDocument to handle the request.
Apache/1.3.37 Server at www.smallgroups.biz Port 80
--
RobbLightfoot - 02 May 2008
I had the exact same problem on a shared host with cpanel (emwd.com), and the workaround by rob to change -w to -s in the shebang at the top of the configure script worked. Seems, though, like someone with more knowledge could figure out what the error message (see top of this thread) means. Thanks folks.
--
TimWegner - 03 May 2008
I can confirm the workaround as well --- the weird thing for me is that it was working for quite some time until i started messing with add-ons. Suddenly the configure script broke? Weird.
--
RedByer - 07 May 2008
worked flawlessly for me under ace-host.net account, just chmod'd all files in /bin/ to 755 and enabled the .htaccess file without the authentication and it flew through like a charm
--
PaulAdams - 14 May 2008
Also on CPanel server. Workaround successful
Changing line 1 of ~/twiki/bin/configure to:
--
KrisThompson - 24 May 2008
Error is confirmed. configure will not run with perl 5.10
See
Bugs:Item5727
where the error is captured and hopefully fixed soon.
--
KennethLavrsen - 23 Jun 2008
We now know more.
The error is in the perl CPAN library CGI.
version 3.37 is know to be buggy and maybe also previous versions. 3.15 is know to now have the problem for sure and probably also versions later.
The error happened when TWiki does this very basic command
$query = new CGI
There are known recorded bugs about this.
which is fixed in 3.38 which was released the 25 Jun 2008 (the day I write this)
We have confirmed upgrading to CGI 3.38 cures the problem.
To verify yourself.
perl -e 'use CGI; print "$CGI::VERSION\n";'
Depending on which distro you use and when you read this, your package manager may already have a new perl for you with a newer CGI. The CGI CPAN lib is normally bundled with perl and not in its own package.
If you do not have an update you can update using CPAN.
perl -MCPAN -e 'upgrade CGI'
which upgrades just CGI to the latest version.
If you are on a shared host - contact your system administrator and ask him to update the CGI CPAN library. Even if configure works without the -w in the shebang line TWiki itself may later show problems and your shared host may be flooded with warning messages.
--
TWiki:Main.KennethLavrsen
- 25 Jun 2008