Re: [Zope-dev] MailHost, 2.2.1, and tracebacks
Bill Anderson wrote: > > Bill Anderson wrote: > ... > > > > The following patch seems to alleviate the problem, but I dunno if it affects >anything else: > > yeah, it makes zope ignore the cookie login setup, and instead triggers basic Auth >... will work on it today. Ugh. Thi sis getting old, replying to my own posts... But anyway, I wa sincorrect, it was a lack of a causing this problem. So far, it works fine. -- Do not meddle in the affairs of sysadmins, for they are easy to annoy, and have the root password. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] MailHost, 2.2.1, and tracebacks
Bill Anderson wrote: ... > > The following patch seems to alleviate the problem, but I dunno if it affects >anything else: yeah, it makes zope ignore the cookie login setup, and instead triggers basic Auth ... will work on it today. Ugh. -- Do not meddle in the affairs of sysadmins, for they are easy to annoy, and have the root password. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] MailHost, 2.2.1, and tracebacks
Shane Hathaway wrote: > > Bill Anderson wrote: ... > > File /local/ZopeSites/TestBed/lib/python/AccessControl/Owned.py, line 152, in >getOwner > > (Object: mailPasswordTemplate) > > ValueError: (see above) > > By any chance does it say something to the effect of "Unpack tuple of > incorrect size"? If so, I suggest you add a "print owner" statement > just before line 152 of Owner.py and tell us what it says. Hi Shane, I apologize for the delay, been working on other aspects of it. I added a print statement, and it prints []. line 52 reads: udb, oid = owner Which makes sense that it would barf, since the list is zero-length. Here is the code bit, with my print statement added in: - def getOwner(self, info=0, aq_get=aq_get, None=None, UnownableOwner=UnownableOwner, ): """Get the owner If a true argument is provided, then only the owner path and id are returned. Otherwise, the owner object is returned. """ owner=aq_get(self, '_owner', None, 1) if owner is None: return owner if info: return owner if owner is UnownableOwner: return None print owner udb, oid = owner root=self.getPhysicalRoot() udb=root.unrestrictedTraverse(udb, None) if udb is None: return SpecialUsers.nobody owner = udb.getUserById(oid, None) if owner is None: return SpecialUsers.nobody return owner -- The following patch seems to alleviate the problem, but I dunno if it affects anything else: == --- lib/python/AccessControl/Owned.py Mon Sep 4 13:56:52 2000 +++ lib/python/AccessControl/Owned.py Mon Sep 4 13:55:40 2000 @@ -149,6 +149,8 @@ if owner is UnownableOwner: return None +if len(owner)==0: return None + udb, oid = owner root=self.getPhysicalRoot() udb=root.unrestrictedTraverse(udb, None) === Basically, I test for an empty list, and return None. -- Do not meddle in the affairs of sysadmins, for they are easy to annoy, and have the root password. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] MailHost, 2.2.1, and tracebacks
Bill Anderson wrote: > > OK, I've bee trailing this bug for quite some time, and haven't found a solution >other than not use 2.2.1 :( > (snip) > File /local/ZopeSites/TestBed/lib/python/OFS/DTMLMethod.py, line 172, in __call__ > (Object: mailPasswordTemplate) > File /local/ZopeSites/TestBed/lib/python/DocumentTemplate/DT_String.py, line 528, >in __call__ > (Object: mailPasswordTemplate) > File /local/ZopeSites/TestBed/lib/python/Products/MailHost/SendMailTag.py, line >182, in render > (Object: MailHost) > File /local/ZopeSites/TestBed/lib/python/OFS/DTMLMethod.py, line 194, in validate > (Object: mailPasswordTemplate) > File /local/ZopeSites/TestBed/lib/python/AccessControl/SecurityManager.py, line >139, in validate > File /local/ZopeSites/TestBed/lib/python/AccessControl/ZopeSecurityPolicy.py, line >178, in validate > File /local/ZopeSites/TestBed/lib/python/AccessControl/Owned.py, line 152, in >getOwner > (Object: mailPasswordTemplate) > ValueError: (see above) By any chance does it say something to the effect of "Unpack tuple of incorrect size"? If so, I suggest you add a "print owner" statement just before line 152 of Owner.py and tell us what it says. Shane ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )