[Zope-dev] DocumentLibrary 1.0b3 / Zope 2.4.2 (newbie?) problem
Hi, any attempt to submit a document to my newly created document library under zope 2.4.2 yields the following error (traceback appended below): Error Type: NameError Error Value: global name 'ZopeTime' is not defined Now that's an error so basic that I suspect that it's me who is doing something wrong---if I only knew what...! Any help would be highly appreciated! Best, ...hap Traceback (innermost last): File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/Publish.py, line 223, in publish_module File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/Publish.py, line 187, in publish File /data1/software/Zope/zope-2.4.2/lib/python/Zope/__init__.py, line 226, in zpublisher_exception_hook (Object: library) File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/Publish.py, line 171, in publish File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: document_submit) File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: document_submit) File /data1/software/Zope/zope-2.4.2/lib/python/OFS/DTMLMethod.py, line 195, in __call__ (Object: document_submit) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_String.py, line 546, in __call__ (Object: document_submit) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_Try.py, line 212, in render File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_Try.py, line 221, in render_try_except File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_With.py, line 148, in render (Object: Documents) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_With.py, line 133, in render (Object: addDocumentFile(REQUEST)) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_Util.py, line 231, in eval (Object: addDocumentFile(REQUEST)) (Info: REQUEST) File string, line 2, in f File /data1/software/Zope/zope-2.4.2/Products/DocumentLibrary/DocumentStore.py, line 355, in addDocumentFile (Object: Documents) File /data1/software/Zope/zope-2.4.2/lib/python/OFS/ObjectManager.py, line 324, in _setObject (Object: Documents) File /data1/software/Zope/zope-2.4.2/lib/python/Products/ZCatalog/CatalogAwarenes s.py, line 114, in manage_afterAdd (Object: 1004694129.27) File /data1/software/Zope/zope-2.4.2/lib/python/Products/ZCatalog/CatalogAwarenes s.py, line 184, in index_object (Object: 1004694129.27) File /data1/software/Zope/zope-2.4.2/Products/DocumentLibrary/CatalogPlus.py, line 122, in catalog_object File /data1/software/Zope/zope-2.4.2/lib/python/Products/ZCatalog/Catalog.py, line 382, in catalogObject File /data1/software/Zope/zope-2.4.2/lib/python/Products/ZCatalog/Catalog.py, line 495, in recordify File /data1/software/Zope/zope-2.4.2/lib/python/OFS/DTMLMethod.py, line 188, in __call__ (Object: date) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_String.py, line 546, in __call__ (Object: date) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_Util.py, line 231, in eval (Object: ZopeTime().Date()) (Info: ZopeTime) File string, line 2, in f (Object: guarded_getattr) NameError: (see above) ___ 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 )
[Zope-dev] Re: [Zope] CoreSession Urgent !!!
Hi, thanks for hammering it out. The problems persit on my Site(2.3.3) under Win2k and OSX. CST 0.8 works fine. You tried to use 2 session Manager in 1 Transaktion simultaneously ? perhaps in 1 method ? micha - Original Message - From: Andreas Jung [EMAIL PROTECTED] To: michael kobald [EMAIL PROTECTED]; [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Thursday, November 01, 2001 6:33 PM Subject: Re: [Zope] CoreSession Urgent !!! Michel, I tried to reproduce the problem without success. I installed CST 0.9 under Linux and XP and hammered it with ab. I did not get any errors, sorry :-( Andreas - Original Message - From: michael kobald [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Thursday, October 25, 2001 09:26 Subject: [Zope] CoreSession Urgent !!! Hi, i am have a big Problem with CoreSession 0.9 (Zope 2.3.3 Win2000 Server). I have 2 Session Data Mangers (dieter and session_mgr). I i want call the getSessionData() of them both method in 1 Transaction. Via calling foo3 I get the error msgs below. I need to call both Data Mangers in 1 Transaction ! By the way: Zope 2.4.2 hangs for the rest of his live after the 2. calling of foo3 Please Help michael Code: def a(self): khjkjh data = self.dieter.getSessionData() data.set('dfd', 'dsd') return None def b(self): hjhjh data2 = self.session_mgr.getSessionData() return None def foo3(self, REQUEST): hhjh #return dgffdg c = self.a() #get_transaction().commit(1) d= self.b() #data = self.session_mgr.getSessionData() return huhuh First Call Error Type: error Error Value: release unlocked lock Traceback (innermost last): File E:\Beehive\TeDeLine\lib\python\ZPublisher\Publish.py, line 223, in publish_module File E:\Beehive\TeDeLine\lib\python\ZPublisher\Publish.py, line 187, in publish File E:\Beehive\TeDeLine\lib\python\Zope\__init__.py, line 221, in zpublisher_exception_hook (Object: Traversable) File E:\Beehive\TeDeLine\lib\python\ZPublisher\Publish.py, line 175, in publish File E:\Beehive\TeDeLine\lib\python\Zope\__init__.py, line 235, in commit File E:\Beehive\TeDeLine\lib\python\ZODB\Transaction.py, line 335, in commit File E:\Beehive\TeDeLine\lib\python\ZODB\Connection.py, line 657, in tpc_finish File E:\Beehive\TeDeLine\lib\python\ZODB\BaseStorage.py, line 219, in tpc_finish (Object: SessionStorage) error: (see above) Second Call: Error Type: TransactionErrorError Value: A serious error, which was probably a system error, occurred in a previous database transaction. This application may be in an invalid state and must be restarted before database updates can be allowed. Beware though that if the error was due to a serious system problem, such as a disk full condition, then the application may not come up until you deal with the system problem. See your application log for information on the error that lead to this problem. ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev ) ___ 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] DocumentLibrary 1.0b3 / Zope 2.4.2 (newbie?) problem
Hi, Are you using dtml-var ZopeTime().Date() instead of dtml-var _.ZopeTime().Date() ZopeTime I suspect doesn't come from the local namespace. Cheers, Paul Zwarts -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On Behalf Of Kolb, Hap Sent: Friday, November 02, 2001 11:26 AM To: '[EMAIL PROTECTED]' Subject: [Zope-dev] DocumentLibrary 1.0b3 / Zope 2.4.2 (newbie?) problem Hi, any attempt to submit a document to my newly created document library under zope 2.4.2 yields the following error (traceback appended below): Error Type: NameError Error Value: global name 'ZopeTime' is not defined Now that's an error so basic that I suspect that it's me who is doing something wrong---if I only knew what...! Any help would be highly appreciated! Best, ...hap Traceback (innermost last): File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/Publish.py, line 223, in publish_module File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/Publish.py, line 187, in publish File /data1/software/Zope/zope-2.4.2/lib/python/Zope/__init__.py, line 226, in zpublisher_exception_hook (Object: library) File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/Publish.py, line 171, in publish File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: document_submit) File /data1/software/Zope/zope-2.4.2/lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: document_submit) File /data1/software/Zope/zope-2.4.2/lib/python/OFS/DTMLMethod.py, line 195, in __call__ (Object: document_submit) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_String.py , line 546, in __call__ (Object: document_submit) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_Try.py, line 212, in render File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_Try.py, line 221, in render_try_except File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_With.py, line 148, in render (Object: Documents) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_With.py, line 133, in render (Object: addDocumentFile(REQUEST)) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_Util.py, line 231, in eval (Object: addDocumentFile(REQUEST)) (Info: REQUEST) File string, line 2, in f File /data1/software/Zope/zope-2.4.2/Products/DocumentLibrary/DocumentStore.p y, line 355, in addDocumentFile (Object: Documents) File /data1/software/Zope/zope-2.4.2/lib/python/OFS/ObjectManager.py, line 324, in _setObject (Object: Documents) File /data1/software/Zope/zope-2.4.2/lib/python/Products/ZCatalog/CatalogAwar enes s.py, line 114, in manage_afterAdd (Object: 1004694129.27) File /data1/software/Zope/zope-2.4.2/lib/python/Products/ZCatalog/CatalogAwar enes s.py, line 184, in index_object (Object: 1004694129.27) File /data1/software/Zope/zope-2.4.2/Products/DocumentLibrary/CatalogPlus.py, line 122, in catalog_object File /data1/software/Zope/zope-2.4.2/lib/python/Products/ZCatalog/Catalog.py, line 382, in catalogObject File /data1/software/Zope/zope-2.4.2/lib/python/Products/ZCatalog/Catalog.py, line 495, in recordify File /data1/software/Zope/zope-2.4.2/lib/python/OFS/DTMLMethod.py, line 188, in __call__ (Object: date) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_String.py , line 546, in __call__ (Object: date) File /data1/software/Zope/zope-2.4.2/lib/python/DocumentTemplate/DT_Util.py, line 231, in eval (Object: ZopeTime().Date()) (Info: ZopeTime) File string, line 2, in f (Object: guarded_getattr) NameError: (see above) ___ 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 ) ___ 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] Re: [Zope] CoreSession Urgent !!!
This is unrelated to Michael's original problem, but... However, I kinda find this funcitonality a bit useless since the two objects are not all that independent. All it allows (since you are not allowed yet to have two session_id_mgr) is to set different varialbes with different timeout values. Can be usefull, but not truly persistant where you want it to be. For instance, a simple session cookie that has only the userid would be nice to keep forever, whereas the rest of the session data expires with the browser session. Not currently possible. Actually this is incorrect. First of all, you can have several session_id_mgrs. Tey're a bit tricky to install because you can't add a sessionidmgr in a place where another sessionidmgr can be acquired. This is explained in the docs. A common setup would be to have two folders, A and B and to create A.session_id_mgr and B.session_id_mgr. Second of all, different data managers can point at different data containers. And data containers can have different timeouts like you said. And if you put a data container in your main ZODB ( or at least in some non-RAM-backed storage), and set its timeout to 0, things that are put into it will never expire. This is what you seem to want. This is also explained further in the docs. Cheers, - C ___ 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] Zope 2.4.2 DTML Method Bug
On Friday 02 November 2001 06:51 am, Steve Alexander allegedly wrote: Matthew T. Kromer wrote: I think that is fixed but I'm not positive that its in 2.4.2 -- I know its on my 2_4 branch; I think we just barely missed this for 2.4.2 -- I see the change going into the log about a week later. I'll ask Brian if we're going to put out a 2.4.3 to include the fix. Matt, Please see my report in the new Collector. The patch at the end of this email is better than the one in the Collector, and also not mangled by stx :-) Your fix in the trunk does only fixes the symptom. It does not address the problem of DTML Methods not being reenterant. [snip] Here's my patch. As a bonus, we get rid of an unqualified except: statement. Steve, Your fix seems correct to me, just swallowing the exception is probably a subtle security hole at worst at best it is just sweeping things under the rug as it were. It might be worth stating that constructs such as: try: foo except: pass Smack of bad form and should be avoided at all costs... They can make debugging a nightmare. It would be nice if this patch could make it into 2.4.3b3. Thanks Steve! /---\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association [EMAIL PROTECTED] \---/ ___ 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 )