Item12238: AllowLoginName breaks Func::wikiNameToEmails if WikiUsers topic is not valid.
Priority: Enhancement
Current State: Confirmed
Released In: n/a
Target Release: n/a
Marking this as a blocker for 1.2, as I don't understand the issue.
It appears that Foswiki::Func::wikinameToEmails is no longer returning any addresses on trunk. The last successful run I've seen was on 27 Oct 2012. After the 27th, the script was generating errors:
tools/develop/plague.pl: Item10001: Main.KennethLavrsen has no email address
tools/develop/plague.pl: Item10011: Main.SvenDowideit has no email address
...
Code in question:
foreach my $waitname ( split( /[,\s]/, $waitingFor ) ) {
$waitname =~ s/Foswiki://;
my @waitemails = Foswiki::Func::wikinameToEmails($waitname);
push @emails, @waitemails;
}
unless ( scalar(@emails) ) {
print STDERR "$0: $topic: $waitingFor has no email address\n";
next;
}
When run under 1.1.6, it all works fine. I've changed the cronjob to run under 1.1.6 unit this is debugged. Marking urgent for 1.2.
Resolved - false alarm. Someone (me) had enabled "AllowLoginName" on trunk. With
TopicUserMapping, this
requires a valid
WikiUsers topic, which trunk does not have. So the code to get the cUID from the
LoginName /
WikiName failed to return anything.
We might want a config checker to warn that if
AllowLoginName is enabled, a valid
WikiUsers topic is required. Or maybe even a button that will validate
WikiUsers against .htpasswd, using the new config architecture for 1.2. Changing to an enhancement request.
--
GeorgeClark - 12 Nov 2012