a bug in updating to current cvs :
Traceback (most recent call last): File "bin/update", line 531, in ? errors = main() File "bin/update", line 413, in main errors = errors + dolist(listname) File "bin/update", line 183, in dolist mlist = MailList.MailList(listname, lock=0) File "/home/mailman/Mailman/MailList.py", line 101, in __init__ self.Load() File "/home/mailman/Mailman/MailList.py", line 546, in Load self.CheckVersion(dict) File "/home/mailman/Mailman/MailList.py", line 557, in CheckVersion self.InitVars() File "/home/mailman/Mailman/MailList.py", line 331, in InitVars baseclass.InitVars(self) File "/home/mailman/Mailman/Archiver/Archiver.py", line 110, in InitVars }, mlist=self)) File "/home/mailman/Mailman/Utils.py", line 484, in maketext raise IOError(errno.ENOENT, 'No template file found', templatefile) IOError: [Errno 2] No template file found: 'emptyarchive.html' make: *** [update] Erreur 1
-- Fil
"Fil" == Fil <fil@rezo.net> writes:
<snip> || file found', templatefile) IOError: [Errno 2] No template file || found: 'emptyarchive.html' make: *** [update] Erreur 1
I think that this one is my fault if you use FR as default Lang, FR templates aren't updated yet, I'll manage to do it this night. My apologies.
Cheers.
-- Ousmane Wilane
I hadn't thought about the situation where your default site language is not 'en' and the language which /is/ your site language is missing a template. Mailman should always fall back to the English template as a last resort. Can you try this (untested) patch -- before Ousmane checks in the French emptyarchive.html file? I'm in a meeting so I can't test this yet myself, but I will later tonight. If it works, I'll check this in. Thanks, -Barry Index: Utils.py =================================================================== RCS file: /cvsroot/mailman/mailman/Mailman/Utils.py,v retrieving revision 2.25 diff -u -r2.25 Utils.py --- Utils.py 2002/01/06 07:49:03 2.25 +++ Utils.py 2002/01/07 23:02:46 @@ -480,8 +480,14 @@ except quickexit: pass if fp is None: - # We never found the template. BAD! - raise IOError(errno.ENOENT, 'No template file found', templatefile) + # Try one last time with the distro English template, which, unless + # you've got a really broken installation, must be there. + try: + fp = open(os.path.join(mm_cfg.TEMPLATE_DIR, 'en', templatefile)) + except IOError, e: + if e.errno <> errno.ENOENT: raise + # We never found the template. BAD! + raise IOError(errno.ENOENT, 'No template file found', templatefile) template = fp.read() fp.close() text = template
"BAW" == Barry A Warsaw <barry@zope.com> writes:
BAW> Can you try this (untested) patch -- before Ousmane checks in
BAW> the French emptyarchive.html file? I'm in a meeting so I
BAW> can't test this yet myself, but I will later tonight. If it
BAW> works, I'll check this in.
It works for me, so I've checked it in. Thanks to Ousmane for checking in the new French template.
-Barry
participants (3)
-
barry@zope.com
-
Fil
-
Ousmane Wilane