Re: [Zope] Zope 2.8 and conflict errors
[Tim Peters] >> Offhand it looks OK to me, but I don't have any of the code you're >> using. [Maciej Wisniowski] > I think that it's not my code problem but rather something with > DCOracle2 and to reproduce this error it is enough to call > any 'DCOracle2 StoredProcedure' object simultaneously > by a lot of users (50 is enough for my Zope (ZEO) to cause these > errors). Sorry, I'm not making myself clear: I don't have _any_ of the code you're using, including DCOracle2. I don't use it -- and I don't have time to try to figure out how to use it. But I know the code paths in ZODB on the way toward calling _p_resolveConflict, and if I did have the code you were using, this is what I'd do: >> If you want to dig deeper, look into what happens inside >>lib/python/ZODB/ConflictResolution.py > I'll try to check this, thanks for the hint. :) It's the only way you'll figure it out ;-) ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Zope 2.8 and conflict errors
Offhand it looks OK to me, but I don't have any of the code you're using. I think that it's not my code problem but rather something with DCOracle2 and to reproduce this error it is enough to call any 'DCOracle2 StoredProcedure' object simultaneously by a lot of users (50 is enough for my Zope (ZEO) to cause these errors). If you want to dig deeper, look into what happens inside lib/python/ZODB/ConflictResolution.py I'll try to check this, thanks for the hint. :) -- Maciej Wisniowski ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Zope 2.8 and conflict errors
Assignments to "_v_" attributes (they are so called "volatile" attributes) do not change the persistent state and cannot cause conflicts. There must be some other modification to the procedure objects. I should have written: "It's possibly because of _connect method in DCOracle2 SP.py. It assigns values to self._v_proc, self.connection and self.errors." So except '_v_proc' there are 'connection' and 'errors' variables that are being assigned to. Maybe this it's because of them. -- Maciej Wisniowski ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Need to find RSS product
Hi all: Any recommendation for a RSS product. Indeed what i want is a client to obtain information from a RSS server and present this in a page. Thanks in advanced !!! ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Zope 2.8 and conflict errors
[Maciej Wisniowski, wrestling with _p_resolveConflict] > Because of errors like: > > ConflictError: database conflict error (oid 0x0299de, class > Products.DCOracle2.DA.Procedure, serial this txn started with > 0x035f0726c7bfca88 2005-08-01 08:38:46.816215, serial currently > committed 0x035f072fed78ebee 2005-08-01 08:47:55.657582) > > and according to: > http://www.upfrontsystems.co.za/Members/jean/conflicterrors-explained > I've added: > > def _p_resolveConflict(self, old, saved, new): >print 'old:', old >print 'saved:', saved >print 'new:', new >return new > > to SP.py into procedure class (DA.Procedure extends this), > > I've started Zope with runzope and there are no 'old':?, 'new':?, > 'saved:?' statements at all on the console although other print > statements from SP.Procedure are visible. > > Maybe these conflict errors I'm dealing with are different kind and > are not falling into the correct piece of code or maybe this kind > of test (print 'something') is too stupid to see if _p_resolveConflict > is executed? Offhand it looks OK to me, but I don't have any of the code you're using. If you want to dig deeper, look into what happens inside lib/python/ZODB/ConflictResolution.py in function tryToResolveConflict(). If your _p_resolveConflict() were getting called, you would see the print output you coded. Therefore it's not getting called. tryToResolveConflict() is what _tries_ to call it (assuming that for an instance `object` of this type, getattr(object, "_p_resolveConflict", None) returns a non-None value to begin with, which I can't tell for sure from what you've said). ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Zope 2.8 and conflict errors
Maciej Wisniowski wrote at 2005-8-5 23:37 +0200: >> Do you see a reason why your requests modify "Procedure" instances? >> I find this strange: I would expect that they are rarely modified >> (just once to set them up). >It's possibly because of _connect method in DCOracle2 SP.py. It >assigns to self _v_proc, connection, and errors count. Assignments to "_v_" attributes (they are so called "volatile" attributes) do not change the persistent state and cannot cause conflicts. There must be some other modification to the procedure objects. -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] AttributeError in DocFinder 1.0.3
Kate Legere wrote at 2005-8-5 15:04 -0400: >I've installed DocFinder 1.0.3 but I'm getting an error when I try to >instantiate. > ... >Exception Type AttributeError >Exception Valuestandard_template.pt "standard_template.pt" is one of the standard objects you should find in your Zope "Root Folder" (in the ZMI). Its companions are "standard_error_message", "standard_html_footer" and "standard_html_header". Maybe, your Zope instance is very old (from a time when "standard_template.pt" was not yet created). "standard_template.pt" is a Page Template with the following content: The Title This is where the page's body text goes. abc -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Pluggable Brains
David H wrote at 2005-8-6 13:12 -0700: >I've been using "pluggable brains" in some zSQL classes. I have some >questions! > >a) It seems if I initialize a variable in the __init__ method that >variable, say self.callCount = 1 is not retained across calls, eg For efficiency reasons, the result row objects of Z SQL methods do not have a dict. Therefore, you cannot create new attributes for them. Your brain classes derive from such objects and therefore, too, lack a dict. -- Dieter ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] REStructuredText and Title
I am adding ReStructuredText documents through the ZMI and I noticed that I am unable to set the 'Title' attribute. Am I missing something? When adding a document the 'ID' also shows up in the 'Title' section, and I can't find a way through the interface to change the 'Title'. Perhaps there is a way to hack it in? Any help, tips, or pointers would be appreciated. Platform: (Zope 2.7.5-final, python 2.3.5, freebsd5) Thanks, -Justin ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Metaclasses in ZOPE Products
--On 7. August 2005 19:02:51 +0200 Jan-Ole Esleben <[EMAIL PROTECTED]> wrote: Hi! What do I need to do to derive a new base class for my products from item that defines its own meta class? There's a whole mess of code in the Zope source code that deals with meta classes, but nothing I can actually identify as the thing to do. I am deriving from SimpleItem at the moment. Currently, I use a meta class derived from type, but this doesn't work: File "E:\Python23\lib\fliwas\ccitem.py", line 54, in ? class CCItem(SimpleItem): File "E:\Python23\lib\fliwas\ccmethods.py", line 38, in __new__ return type.__new__(cls, name, bases, classdict) TypeError: metaclass conflict: the metaclass of a derived class must be a (non-s trict) subclass of the metaclasses of all its bases I don't know much about meta-classes but I think you require new-style classes for working with meta-classes. This implies that you need at least Zope 2.8 since new-style classes conflict with Zope ExtensionClasses in pre-Zope 2.8 versions. -aj pgpNQxkCjgxHT.pgp Description: PGP signature ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Metaclasses in ZOPE Products
Hi! What do I need to do to derive a new base class for my products from item that defines its own meta class? There's a whole mess of code in the Zope source code that deals with meta classes, but nothing I can actually identify as the thing to do. I am deriving from SimpleItem at the moment. Currently, I use a meta class derived from type, but this doesn't work: File "E:\Python23\lib\fliwas\ccitem.py", line 54, in ? class CCItem(SimpleItem): File "E:\Python23\lib\fliwas\ccmethods.py", line 38, in __new__ return type.__new__(cls, name, bases, classdict) TypeError: metaclass conflict: the metaclass of a derived class must be a (non-s trict) subclass of the metaclasses of all its bases I'm guessing that using a certain base class for my meta class should work, but the documentation doesn't say (as far as I can find out). TIA, Ole ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] CMF 1.5.3 released
The CMF developer community and Zope Corporation are pleased to announce the release of version 1.5.3 of the Zope Content Management Framework (CMF). This release marks the latest stable release in the CMF 1.5 series and should be suitable for production use. What is the CMF? The Zope Content Management Framework provides a set of services and content objects useful for building highly dynamic, content-oriented portal sites. As packaged, the CMF generates a site much like the Zope.org site. The CMF is intended to be easily customizable, in terms of both the types of content used and the policies and services it provides. Where do I get it? Download it from http://zope.org/Products/CMF/CMF-1.5.3 Points of interest include: - "Windows ZIP file", http://zope.org/Products/CMF/CMF-1.5.3/CMF-1.5.3.zip - "Unix tar/gzip archive", http://zope.org/Products/CMF/CMF-1.5.3/CMF-1.5.3.tar.gz - "Release notes", http://zope.org/Products/CMF/CMF-1.5.3/README.txt - "Change history", http://zope.org/Products/CMF/CMF-1.5.3/CHANGES.txt - "Installation instructions", http://zope.org/Products/CMF/CMF-1.5.3/INSTALL.txt Where do I go to learn more? The "CMF mailing list":mailto:[EMAIL PROTECTED] has many participants who are active in supporting the CMF. ...to report bugs? The "CMF Collector":http://zope.org/Collectors/CMF is ths place to report bugs (please search for existing reports of your issue first!) - Jens Vagelpohl [EMAIL PROTECTED] ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )