This question about Installation of Foswiki: Answered
Foswiki/Users/HtPasswdUser.pm did not return a true value
I've installed Foswiki 1.0.5 on a subdomain of my domain at
DreamHost, but I am having problems with the password manager:
- When I
view
a page, I get the error listed below.
- To troubleshoot this, I tried to set the password manager to
none
in configure, and the pages then view just fine. So I think it's not a permission thing in bin
or in data
.
- When I set it to
HtPasswdUser
I get the error listed. When I try ApacheHtpasswdUser
instead, I get a different error but still no success.
- I've checked that all paths in
configure
are correct, including the path to .htpasswd
which is also set to 0644
.
- I've also googled, and searched here, for keywords in the error message, but I came up blank.
- I've installed TWiki several times over the years and feel I am reasonably well versed. But this is my first Foswiki 1.0.5 install. One Foswiki 1.0.0 install I did earlier succeeded, but I can't determine any difference.
--> How can I resolve this error?
Software error:
Foswiki/Users/HtPasswdUser.pm did not return a true value at (eval 26) line 3.
at (eval 26) line 3
eval 'require Foswiki::Users::HtPasswdUser
;' called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Users/TopicUserMapping.pm line 81
Foswiki::Users::TopicUserMapping::new('Foswiki::Users::TopicUserMapping', 'Foswiki=HASH(0xb34740)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Users.pm line 123
Foswiki::Users::new('Foswiki::Users', 'Foswiki=HASH(0xb34740)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki.pm line 1352
Foswiki::new('Foswiki', 'undef', 'Foswiki::Request=HASH(0x525c80)', 'HASH(0xb1d5a0)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/UI.pm line 276
Foswiki::UI::_execute('Foswiki::Request=HASH(0x525c80)', 'CODE(0xb34880)', 'view', 1) called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/UI.pm line 258
Foswiki::UI::handleRequest('Foswiki::Request=HASH(0x525c80)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Engine/CGI.pm line 26
Foswiki::Engine::CGI::run('Foswiki::Engine::CGI=HASH(0x92e790)') called at view line 45
For help, please send mail to the webmaster (webmaster@lex.gebeconsult.com), giving this error message and the time and date of the error.
Software error:
[Fri Jun 19 22:05:10 2009] view: Foswiki/Users/HtPasswdUser.pm did not return a true value at (eval 26) line 3.
[Fri Jun 19 22:05:10 2009] view: at (eval 26) line 3
[Fri Jun 19 22:05:10 2009] view: eval 'require Foswiki::Users::HtPasswdUser
[Fri Jun 19 22:05:10 2009] view: ;' called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Users/TopicUserMapping.pm line 81
[Fri Jun 19 22:05:10 2009] view: Foswiki::Users::TopicUserMapping::new('Foswiki::Users::TopicUserMapping', 'Foswiki=HASH(0xb34740)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Users.pm line 123
[Fri Jun 19 22:05:10 2009] view: Foswiki::Users::new('Foswiki::Users', 'Foswiki=HASH(0xb34740)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki.pm line 1352
[Fri Jun 19 22:05:10 2009] view: Foswiki::new('Foswiki', 'undef', 'Foswiki::Request=HASH(0x525c80)', 'HASH(0xb1d5a0)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/UI.pm line 276
[Fri Jun 19 22:05:10 2009] view: Foswiki::UI::_execute('Foswiki::Request=HASH(0x525c80)', 'CODE(0xb34880)', 'view', 1) called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/UI.pm line 258
[Fri Jun 19 22:05:10 2009] view: Foswiki::UI::handleRequest('Foswiki::Request=HASH(0x525c80)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Engine/CGI.pm line 26
[Fri Jun 19 22:05:10 2009] view: Foswiki::Engine::CGI::run('Foswiki::Engine::CGI=HASH(0x92e790)') called at view line 45
at /usr/share/perl/5.8/CGI/Carp.pm line 314
CGI::Carp::realdie('[Fri Jun 19 22:05:10 2009] view: Foswiki/Users/HtPasswdUser.p...') called at /usr/share/perl/5.8/CGI/Carp.pm line 400
CGI::Carp::die('') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Users/TopicUserMapping.pm line 82
Foswiki::Users::TopicUserMapping::new('Foswiki::Users::TopicUserMapping', 'Foswiki=HASH(0xb34740)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Users.pm line 123
Foswiki::Users::new('Foswiki::Users', 'Foswiki=HASH(0xb34740)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki.pm line 1352
Foswiki::new('Foswiki', 'undef', 'Foswiki::Request=HASH(0x525c80)', 'HASH(0xb1d5a0)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/UI.pm line 276
Foswiki::UI::_execute('Foswiki::Request=HASH(0x525c80)', 'CODE(0xb34880)', 'view', 1) called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/UI.pm line 258
Foswiki::UI::handleRequest('Foswiki::Request=HASH(0x525c80)') called at /home/tomgb/lex.gebeconsult.com/lib/Foswiki/Engine/CGI.pm line 26
Foswiki::Engine::CGI::run('Foswiki::Engine::CGI=HASH(0x92e790)') called at view line 45
For help, please send mail to the webmaster (webmaster@lex.gebeconsult.com), giving this error message and the time and date of the error.
Sounds rather like the perl module has got corrupted. All perl modules have to be terminated with a "true value" - in practice this means that the last (code) line of the file has to be:
1;
Check the Foswiki/Users/HtPasswdUser.pm and ensure it ends this way (the 1; will usually be followed by comments e.g.
1;
__DATA__
Everything after __DATA__ or __END__ is ignored
If the
1;
is missing, then the perl module has been corrupted.
(Another check you can do is to 'cd' to the lib directory and type:
perl -I . Foswiki/Users/HtPasswd.pm
- if you get errors, same analysis)
--
CrawfordCurrie - 29 Jun 2009
Crawford,
thank you! You were absolutely right,
HtPasswdUser.pm
had become corrupted. I would never have found out without your precise comment.
FIXED!
When I investigated this error earlier, I also copied all Foswiki files to the webserver again, overwriting the ones there. I did not notice that
HtPasswdUser.pm
was somehow locked. I noticed it now while investigating your answer, that I was able to open and read the file, but it appeared empty. I could not save any changes. In the end I was able to delete it entirely and then copy over the original from my local system -- and everything immediately began working!
--
TorbenGB - 17 Jul 2009