Item1126: Change in 1.0.1 causes crash when you have standard installation and no LocalLib.cfg and we can no longer run unit tests on Windows
Priority: Urgent
Current State: Closed
Released In: 1.0.2
Target Release: patch
Applies To: Engine
Component:
Branches:
Due to changes in setlib.cfg I can no longer run the unit tests under Windows. It's borked on Linux too, but the error is masked by an eval.
cd d;\foswiki\core\test\unit
perl ../bin/TestRunner.pl -clean -log FoswikiSuite
returns
D:/foswiki/core/test/bin/LocalLib.cfg: No such file or directory at D:/foswiki/core/bin/setlib.cfg line 38
It appears that setlib.cfg now uses
CPAN:FindBin to build an absolute path, which in this case is clearly wrong.
--
CrawfordCurrie - 23 Feb 2009
I fixed this in trunk, but now I'm concerned that this is also broken in 1.0.1. The effect will be that:
cd tools
perl -I ../bin mailnotify.pl
will not work.
Marked for feedback from those who should be concerned.
--
CrawfordCurrie - 23 Feb 2009
In fact, your fix won't work if %INC isn't filled with filenames, as it's the case on FreeBSD, so it seems:
[Mon Feb 23 16:00:02 2009] setlib.cfg: Use of uninitialized value in substitution (s///) at /usr/home/trunk.foswiki.org/core/bin/setlib.cfg line 37.
[Mon Feb 23 16:00:02 2009] setlib.cfg: Use of uninitialized value in -r at /usr/home/trunk.foswiki.org/core/bin/setlib.cfg line 38.
[Mon Feb 23 16:00:02 2009] setlib.cfg: Use of uninitialized value in concatenation (.) or string at /usr/home/trunk.foswiki.org/core/bin/setlib.cfg line 45.
Can't locate Foswiki.pm in @INC (@INC contains: /lib /usr/local/lib/perl5/5.8.8/BSDPAN /usr/local/lib/perl5/site_perl/5.8.8/mach
+/usr/local/lib/perl5/site_perl/5.8.8 /usr/local/lib/perl5/site_perl /usr/local/lib/perl5/5.8.8/mach /usr/local/lib/perl5/5.8.8) at ./view line 46.
at ./view line 46
main::BEGIN() called at Foswiki.pm line 46
eval {...} called at Foswiki.pm line 46
BEGIN failed--compilation aborted at ./view line 46.
at ./view line 46
Committing my
__FILE__
fix so this works.
As for the rest, I've replied on the ML.
--
OlivierRaginel - 23 Feb 2009
Even after SVN 2632 the bin/LocalLib.cfg is still required. If you remove it a very standard Linux based Foswiki fails to find itself.
This worked until some change done today 23rd Feb
--
KennethLavrsen - 23 Feb 2009
That's odd, as
distro:25b0b378bbd0 was made to restore that feature. I've tested it on my local installation, and it works.
It's true that Crawford did the right fix in
distro:42235d0e7a32, then I encountered some issues on FreeBSD thus I created
distro:43e03dc98861, where I changed
do
into
require
, and removed the test for existence of
bin/LocalLib.cfg
, as I thought it had to be required (cf my mail). After chatting with Kenneth and Crawford, it appeared I was mistaken, thus I fixed it in Invalid svn rev, restoring the test for readability of
bin/LocalLib.cfg
.
So please, if you still encounter issue with a post
distro:25b0b378bbd0 trunk clean checkout, I'd appreciate some pointers on the errors. They can be pretty cryptic because they're happening in a BEGIN block, but they still can help diagnose the issue.
--
OlivierRaginel - 24 Feb 2009
Was fixed as I was editing last night
And the SVN number I probably got from looking at last SVN email. Strange that did not trigger me to SVN update?? Well it is fixed. I am happy.
--
KennethLavrsen - 24 Feb 2009