Re: [Zope] Product creation difficulty
Pete Taylor wrote: Error Type: Fault Error Value: Fault 1: 'exceptions.Exception:method echo.__roles__.__contains__ is not supported' Yeah, that's Zope's security mechanisms kicking in. Don't use a python script for this code. Remove your allow_module anduse an external method, like you're supposed to ;-) Either that, or build a python product to do what you want, or use the one that Michael pointed to :-) cheers, Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk ___ 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] The Zope Book
Dieter Maurer wrote: When will they feature in *the* Zope Book? Which The Zope Book are you referring to? The 2.6 one on Zope.org? The 2.7 one on Plope.com? The 3.whatever one somewhere-I-don't-know? It's the age old documentation problem coming back to bite us again :-S cheers, Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk ___ 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] Re: Does anyone care whether we deprecate ZClasses?
Jim Fulton wrote: I wish they were gone, but they are still there. Someday, I'd like to se a TALES-based DTML, but I doubt I'll ever have time to do it. You know that means you want to deprecate it really ;-) I still maintaining ofrcing users to learn two templating languages, one of which is one of the oldest things in the whole framework, is pretty cruel, but then we as a community, do seem to like inflicting new languages on our end users *grinz* Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk ___ 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] Re: login page problem
Dieter Maurer wrote: You are probably right -- but SimpleUserFolder is really simple (which sometimes is good). Simpler is ALWAYS good, as the name of my company kinda gives away ;-) Nothing should ever be less simple than is absolutely necessary! Had *you* used all these reusable components to provide the functionality in SUF, standard users could have used then out of the box -- with just sumitting a configuration page. As it is now, they have to think about (e.g.) cache management and invalidation. All the components I've mentioned so far have been standard Zope components. If their documentation isn't so good, that's a seperate problem. If I provide work-a-likes, then I have to be responsible for that documentation too, which isn't great ;-) That said, maybe I should provide more examples of how to get things like caching and cookie auth working with SUF? I would like to stress that I do not think SUF were bad. I just defend my statement that exUserFolder is something like a big brother to SUF. A bloated fat cousin maybe ;-) cheers, Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk ___ 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] Re: login page problem
Dieter Maurer wrote: The RAMCacheManager is associated with (what I call) site building objects (those have an identifying URL, for example). Why do you think that? User objects are not site building. But in zope, they should always have a url ;-) The UserFolder is but usual implementations do not inherit ZCachable -- and therefore cannot (directly) use the RAMCacheManager. SUF doesn't need to inehrit from ZCacheable... When an object supports transparent caching (which would be necessry for a UserFolder), then it must contain code interfacing with a cache manager. I doubt that SUF contains such code... I think transparency (ie: magic, automagical, and other such bullshit) is bad. Explicit is better that implicit and all that ;-) But hopefully you see that the questions are difficult for a standard user. Only if the standard user needs caching, in which case they should understand the choices they're making ;-) When he uses SUF and determines that caching is needed because authentication and authorization are too costly, he may learn that Z SQL Methods can be cached. Later, he changes some user properties and has to observe that they take effect with a delay (as stale values are cached) and there is no reliable way to flush/invalidate the cache. He may learn that there are CCZSQLMethods the cache of which can be flushed, but he may have had long hours of problems. That seems entirely natural to me. At any time, he can make choices depending on his current needs without being penalised for previous choices... With exUserFolder, he visits the configuration tab and selects with caching for XXX minutes -- that's it (unless he uses ZEO). ...which case he gets core confused and is locked into a caching setup which he'd have to recode at the python level to get anywhere with ;-) cheers, Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk ___ 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] Plone/Zope on Debian Sarge
Robert (Jamie) Munro wrote: There is no standard start up script (as far as I have seen), Then you haven't been looking very hard ;-) zopectl has been standard as of 2.7.0, it can be symlinked right into /etc/init.d and works prettymuch perfectly. to the same port. There's a patch here: http://www.zope.org/Collectors/Zope/1733 If that provides a commandline options to specify a port range, then it's a good patch :-) cheers, Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk ___ 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] The Zope Book
On Apr 8, 2005 8:48 AM, Chris Withers [EMAIL PROTECTED] wrote: Dieter Maurer wrote: When will they feature in *the* Zope Book? Which The Zope Book are you referring to? The 2.6 one on Zope.org? The 2.7 one on Plope.com? The 3.whatever one somewhere-I-don't-know? I would expect it to be featured, that is mentioned as a recommended practice, in a Zope2.9 book, should one appear. I also thonk that with 2.8 a 2.8 book should be released, which main feature could be to move the ZClass part to an appendix. -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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] Does anyone care whether we deprecate ZClasses?
On Apr 8, 2005 12:15 AM, Andreas Pakulat [EMAIL PROTECTED] wrote: Hmm, could you (just for my own interest) point out the difference between PropertySheets and ProperyManager (which I used to define properies for my own product-classes)? IIRC PropertySheets allow to have multiple groups of properties on the same Object, but is there more? If I remember correctly, it also allows you do have the property definition stored somewhere else than on the object itself, and is allows you to store the properties somewhere else than as attributes. It's a bit complex to use, and the property types definitions are too inflexible for practical use, which is why archetypes, CPSSchemas and Zope3 schemas exists now. :-) -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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] Persistent Objects
A coworker of mine wrote his own web server framework from scratch for an internal application. We're looking to migrate this application to Zope (thank God!). The only question we need to deal with is: The reason he wrote his own webserver rather than use CGIs is that there was some processing that needed to happen to initialize a system state -- basically, create an object that knows about the configuration of some things. In his model, this object is created at the beginning and is simply shared among the various Python objects/modules that are invoked when responding to user requests. How can I create such a persistent object that, say, a python script object or a page template could access? (Sure, handholding on this would be nice, but what I'm actually expecting is answers along the lines of look into foo) -roy ___ 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] Persistent Objects
Roy S. Rapoport wrote: A coworker of mine wrote his own web server framework from scratch for an internal application. We're looking to migrate this application to Zope (thank God!). The only question we need to deal with is: The reason he wrote his own webserver rather than use CGIs is that there was some processing that needed to happen to initialize a system state -- basically, create an object that knows about the configuration of some things. In his model, this object is created at the beginning and is simply shared among the various Python objects/modules that are invoked when responding to user requests. How can I create such a persistent object that, say, a python script object or a page template could access? Just write a Python product (there's a bit of boilerplate code, but that's pretty easy) that inherit from persitence.Persistant and can handle all that stuff, and instantiate one at the root of the application. ZODB will take care of the persistence, and acquisition magic will make this object accessible from all the application. (Sure, handholding on this would be nice, but what I'm actually expecting is answers along the lines of look into foo) Look into Product, ZODB, and acquisition !-) -- Bruno Desthuilliers Développeur [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 )
[Zope] best practices Zope filesystem development
Hi, What are the best, most effective practices in leveraging filesystem when developing in Zope? I'm looking for an approach that would let me use keyboard and leave the mouse alone as much as possible. In other words, minimum use of ZMI even if TTW Python Scripts are used extensively. Instead of ZMI/External editor I need vim, grep, mv and cp to manipulate Zope ZODB. -- Milos Prudek ___ 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] best practices Zope filesystem development
--On Freitag, 8. April 2005 11:30 Uhr +0200 Milos Prudek [EMAIL PROTECTED] wrote: Hi, What are the best, most effective practices in leveraging filesystem when developing in Zope? I'm looking for an approach that would let me use keyboard and leave the mouse alone as much as possible. In other words, minimum use of ZMI even if TTW Python Scripts are used extensively. Instead of ZMI/External editor I need vim, grep, mv and cp to manipulate Zope ZODB. CFM + filesystem-based skin methods and templates. Or using ftp/webdav. -aj pgpDsnGXqdG79.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] dtml-tree issue
Hello, I want to use dtml-tree. I want to populate this tree using an external method that like this one: getChildren(parent_id) = [child, child, child, ..] where parent_id is a string and each child is a node (python object). My problem is what kind of object must each node be, in order for the dtml-tree to work properly... The dtml-method is like this (example, hierarchy of links): dtml-tree id=LINK braches_expr=getChildren(LINK) a href=dtml-var LINKdtml-var TITLE/a /dtml-tree I tried a dictionary, but i cannot retrieve the LINK in the branches_expr. I made a class in the External Method with attributes LINK and TITLE, but i get unauthorized exceptions... Thanks for any help, Vangelis ___ 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] Persistent Objects
On Apr 8, 2005 11:05 AM, Roy S. Rapoport [EMAIL PROTECTED] wrote: A coworker of mine wrote his own web server framework from scratch for an internal application. We're looking to migrate this application to Zope (thank God!). The only question we need to deal with is: The reason he wrote his own webserver rather than use CGIs is that there was some processing that needed to happen to initialize a system state -- basically, create an object that knows about the configuration of some things. In his model, this object is created at the beginning and is simply shared among the various Python objects/modules that are invoked when responding to user requests. How can I create such a persistent object that, say, a python script object or a page template could access? Is this persistent even among server restarts, or persistent per request, or persistent per session? (the answer is different for all of them, and usually, in Zope, persistent means persistent over server restarts). -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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] how to set value of hidden form field by a cookie
I've to set the value of a hidden form field by a cookie value. e.g; invalidval request/cookies/login|nothing; i tried this : input name=invalid type=hidden value=string: ${invalidval} and also this input name=invalid type=hidden tal:attributes=value invalidval but it is rendering the text in quotes directly. what is the correct way. -- Share the vision of difference with ME ___ 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] Product creation difficulty
argh! doing it the way i'm supposed to? i don't have time for that! i've got perfectly good banging my head against a wall while ignoring the door right next to me to do! thanks again for the help :). -Original Message- From: Chris Withers [mailto:[EMAIL PROTECTED] Sent: Friday, April 08, 2005 2:45 AM To: Pete Taylor Cc: 'zope@zope.org' Subject: Re: [Zope] Product creation difficulty Pete Taylor wrote: Error Type: Fault Error Value: Fault 1: 'exceptions.Exception:method echo.__roles__.__contains__ is not supported' Yeah, that's Zope's security mechanisms kicking in. Don't use a python script for this code. Remove your allow_module anduse an external method, like you're supposed to ;-) Either that, or build a python product to do what you want, or use the one that Michael pointed to :-) cheers, Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk CONFIDENTIAL NOTICE: This email including any attachments, contains confidential information belonging to the sender. It may also be privileged or otherwise protected by work product immunity or other legal rules. This information is intended only for the use of the individual or entity named above. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution or the taking of any action in reliance on the contents of this emailed information is strictly prohibited. If you have received this email in error, please immediately notify us by reply email of the error and then delete this email immediately. ___ 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] best practices Zope filesystem development
Andreas Jung wrote: --On Freitag, 8. April 2005 11:30 Uhr +0200 Milos Prudek [EMAIL PROTECTED] wrote: Hi, What are the best, most effective practices in leveraging filesystem when developing in Zope? I'm looking for an approach that would let me use keyboard and leave the mouse alone as much as possible. In other words, minimum use of ZMI even if TTW Python Scripts are used extensively. Instead of ZMI/External editor I need vim, grep, mv and cp to manipulate Zope ZODB. CFM + filesystem-based skin methods and templates. Or using ftp/webdav. BTW : there is a non-CFM skin implementation, but I found very few clues about how to use it (being a bit lazy, I'd prefer not having to learn the whole CFM stuff !-). Could someone point me to any exemple, doc or whatsoever so I could get started ? TIA -- Bruno Desthuilliers Développeur [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 )
Re: RES: [Zope] login system discussion
Thanks the request var is set but the next line for redirection ie. return context.index_html renders a new page with text : ZopePageTemplate at index_html is there some object in context which refers to the self page. plz help. On Thu, 7 Apr 2005 11:22:25 -0300, Jose Henrique dos Reis [EMAIL PROTECTED] wrote: I think that request.form['variable'] = value, could solve your problem. I think that RESPONSE.redirect creates another REQUEST object, so all the changes you made in your script are lost. You can use return context.index_html, instead, to preserve the REQUEST. -- Share the vision of difference with ME ___ 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] FW: [newbie] Testing An External Method Object
From: Pier Paolo [mailto:[EMAIL PROTECTED] Sent: Friday, April 08, 2005 2:47 PM To: 'zope@zope.org' Subject: [newbie] Testing An External Method Object Hi everyone! Great work, Im overadmired. I just finished http://www.zope.org/Documentation/Books/ZopeBook/2_6Edition/BasicObject.stx, where I posed a question: Anonymous User - Apr. 8, 2005 7:48 am: Zope 2.7.5-final: My external method was: #def animals_script_2(self, name=Pier Paolo): # id = self.id # return 'Ciao! Sono %s dal %s: external method!' % (name, id) but (in this structure: /zoo/animals_scripts_2 (titles: Zope Zoo, TheANIMall 2)) it returned: Ciao! Sono Pier Paolo dal (...OK) zoo (...!): external method! I tried a title = self.title in the ext script but the problem was the same: Ciao! Sono Pier Paolo dal Zope Zoo ... So: Why my external script refer to his parent object?? (sorry for my english and my python.) = I would like a response, or some links to learn how zope manage dependencies (if thats the real problem, and I havent made too much mistakes). PS: I dont know if this is the right place to post a question on the Zope Book, hope so. Thanks, Pier Paolo. ___ 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] Zope/python: downloading images from the web and add them to Zope
I would like to know how to add image file from an URL. I created a form with to pissibilities: add an image from a local file , and a image from an url here is my form: input type=radio name=sourcePicture checked onClick=lock_option() value=file get from disk: input type=file name=pict_file size=40 accept=image maxlength=50 br input type=radio name=sourcePicture onClick=lock_option() value=internet get from the internetinput type=text name=pict_internet size=40 value=http://www.monsite.fr/monimage.jpg; disabled=disabled This form call a python script: if REQUEST.sourcePict==file: pathImgs.manage_addProduct['OFSP'].manage_addImage(pict_+id, REQUEST.pict_file, title=pictogramme metier, precondition=, content_type=) else: pathImgs.manage_addProduct['OFSP'].manage_addImage(pict_+id, REQUEST.pict_internet, title=pictogramme metier, precondition=, content_type=) With a locl file it works (case sourcePict=file), but when I want to add images from an url, it doesn't work. I suppose that the second parameter of manage_addImage must be a file type.In the first case, it works , but in the second, the parameter passed is a string (complete url of the image). so how to do? thanks for your answers and excuse me for the lack in English (I'm french) ___ 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] best practices Zope filesystem development
Yup. http://www.zope.org/Members/mcdonc/Products/Standalone%20Skins%20Tool On Fri, 2005-04-08 at 08:08, bruno modulix wrote: Andreas Jung wrote: --On Freitag, 8. April 2005 11:30 Uhr +0200 Milos Prudek [EMAIL PROTECTED] wrote: Hi, What are the best, most effective practices in leveraging filesystem when developing in Zope? I'm looking for an approach that would let me use keyboard and leave the mouse alone as much as possible. In other words, minimum use of ZMI even if TTW Python Scripts are used extensively. Instead of ZMI/External editor I need vim, grep, mv and cp to manipulate Zope ZODB. CFM + filesystem-based skin methods and templates. Or using ftp/webdav. BTW : there is a non-CFM skin implementation, but I found very few clues about how to use it (being a bit lazy, I'd prefer not having to learn the whole CFM stuff !-). Could someone point me to any exemple, doc or whatsoever so I could get started ? TIA ___ 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] symbols undefined after product refresh?
On Apr 8, 2005, at 15:20, Jürgen Herrmann wrote: hi! after reloading my own products through the zmi it seems like some classes and methods gets undefined. please see the following traceback: Refresh is *not* the panacea to avoid all restarts. If things get funky, restart. Simple as that. jens ___ 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] ZPT and attributes
Hi all: How I can create attribute names dynamically? For example, I want something like this: books ref1=http://boo; ref2=http://foo; ... Where ref1 and ref2, are created by the url list. I have done in DTML because I cannot with ZPT. Thanks... ___ 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] ZPT and attributes
On Apr 8, 2005 4:51 PM, Antonio Beamud Montero [EMAIL PROTECTED] wrote: Hi all: How I can create attribute names dynamically? tal:attributes=attributename expression For example, I want something like this: books tal:attributes=ref1 string:http://boo;; ref2 request/URL3 / And so on. -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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] Re: symbols undefined after product refresh?
On Fri, Apr 08, 2005 at 03:20:52PM +0200, Jrgen Herrmann wrote: [...] | ps: this does not only happen to my SubClassCatalog, this also hits | f.ex. from random import randint where randint gets undefined. That makes sense. The 'from-import' syntax creates a name in the local namespace that refers to the indicated object. If you reload the module you imported from, then that object is going to go away (or at least be re-constructed) and the reference you had may no longer be valid. It may be the case that reloading your module fails to properly handle all of the imports. Basically that's just the way it is and it is difficult to try and implement reload completely correctly (which is what Zope's refresh depends on ). As has already been noted, simply restart and you definitely won't have any problems. Use a faster machine if the restart time is too long ;-). HTH, -D -- One OS to rule them all, one OS to find them, One OS to bring them all and in the darkness bind them, In the Land of Redmond, where the Shadows lie. www: http://dman13.dyndns.org/~dman/jabber: [EMAIL PROTECTED] signature.asc Description: Digital 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 )
Re: [Zope] ZPT and attributes
El vie, 08-04-2005 a las 16:55 +0200, Lennart Regebro escribió: On Apr 8, 2005 4:51 PM, Antonio Beamud Montero [EMAIL PROTECTED] wrote: Hi all: How I can create attribute names dynamically? tal:attributes=attributename expression Sorry, I haven't explain the problem correctly :) The problem is the number of refX depends on the list of urls, i.e. if I have ['http://foo', 'http://boo', 'http://google.com'] then I create: books ref1='http://foo' ref2='http://boo' ref3='http://google.com' but with ['http://foo'] I create: books ref1='http://foo' How I create refX? Greetings. For example, I want something like this: books tal:attributes=ref1 string:http://boo;; ref2 request/URL3 / And so on. ___ 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] ZPT and attributes
On Apr 8, 2005 5:00 PM, Antonio Beamud Montero The problem is the number of refX depends on the list of urls, i.e. if I have ['http://foo', 'http://boo', 'http://google.com'] then I create: books ref1='http://foo' ref2='http://boo' ref3='http://google.com' but with ['http://foo'] I create: books ref1='http://foo' Ah. How I create refX? I have no idea if that's even possible. -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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/python: downloading images from the web and add them to Zope]
[EMAIL PROTECTED] wrote: I would like to know how to add image file from an URL. I created a form with to pissibilities: add an image from a local file , and a image from an url You can get an image from a url with an External Method: # Get an image using the original url. import urllib def getImage(url): f = urllib.urlopen(url) data = f.read() f.close() return data Hope this is enough to put you on track. Cliff here is my form: input type=radio name=sourcePicture checked onClick=lock_option() value=file get from disk: input type=file name=pict_file size=40 accept=image maxlength=50 br input type=radio name=sourcePicture onClick=lock_option() value=internet get from the internetinput type=text name=pict_internet size=40 value=http://www.monsite.fr/monimage.jpg; disabled=disabled This form call a python script: if REQUEST.sourcePict==file: pathImgs.manage_addProduct['OFSP'].manage_addImage(pict_+id, REQUEST.pict_file, title=pictogramme metier, precondition=, content_type=) else: pathImgs.manage_addProduct['OFSP'].manage_addImage(pict_+id, REQUEST.pict_internet, title=pictogramme metier, precondition=, content_type=) With a locl file it works (case sourcePict=file), but when I want to add images from an url, it doesn't work. I suppose that the second parameter of manage_addImage must be a file type.In the first case, it works , but in the second, the parameter passed is a string (complete url of the image). so how to do? thanks for your answers and excuse me for the lack in English (I'm french) ___ 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 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] The Zope Book
I don't think anyone has given much thought to actually documenting all these nice nifty features in 2.9. Which is no change from the norm, and it will be a fairly organic process again. I hate it, but whatever. - C On Fri, 2005-04-08 at 11:22, Paul Winkler wrote: On Fri, Apr 08, 2005 at 10:59:46AM +0200, Lennart Regebro wrote: On Apr 8, 2005 8:48 AM, Chris Withers [EMAIL PROTECTED] wrote: Dieter Maurer wrote: When will they feature in *the* Zope Book? Which The Zope Book are you referring to? The 2.6 one on Zope.org? The 2.7 one on Plope.com? The 3.whatever one somewhere-I-don't-know? I would expect it to be featured, that is mentioned as a recommended practice, in a Zope2.9 book, should one appear. I also thonk that with 2.8 a 2.8 book should be released, which main feature could be to move the ZClass part to an appendix. I would love that. But in the present day, we haven't even finished the 2.7 book. I suppose we could just change the book's release number from 2.7 to 2.8 and hope that's adequate ;-) But that leaves unanswered questions - should we document the Five stuff at all, and if so, how? The primary problem with the Zope Book is still the relative scarcity of resources (i.e. editors with time to work on it). The secondary problem with the Zope Book is that it's showing its age: the choice and organization of topics is IMHO less than ideal, but that can't be sufficiently addressed on a chapter-by-chapter basis, one needs to have a good overview of the whole project. This vastly increases the scope of the task. Sadly I can't see the status quo changing unless somebody wants to invest sufficient money in the project so that some of the independent contractors involved could schedule work on the book as an actual paying job. Hopefully one of two things will happen: * I will be proven wrong, or * such money will materialize somehow :-) ___ 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] The Zope Book
On Fri, Apr 08, 2005 at 05:41:30PM +0200, Lennart Regebro wrote: On Apr 8, 2005 5:22 PM, Paul Winkler [EMAIL PROTECTED] wrote: But that leaves unanswered questions - should we document the Five stuff at all, and if so, how? Well, the Five stuff is a subset of the Zope3 stuff, with way too much Zope2 stuff still necessary. The idea is that this should change quite rapidly and get more and more Zope3-ish and become less and less of a subset. So it may be that documenting it is a bit of a waste of time. I think the most realistic part is to rename the 2.7 book to 2.8, move ZClasses and DTML last, note that 2.8 includes some Zope3 support but don't document it. OK, but there should at least be a pointer to something to read for people wanting to get started with 2.8.0/Five. I haven't yet looked at any of the Five stuff. Is there at least a README? :) Then we'll concentrate on getting 2.9s Zope3 support to be more Zope3-ish, and documenting the differences into a Zope2.9 book. ;) Yes, I'm sure we will ;-) I don't have an overview of what needs to be done on the Zope book in general though. Well, the chapter-by-chapter editing is still not done. See http://plope.com/Books/zb_signup for an overview of the known tasks to be done. -- Paul Winkler http://www.slinkp.com ___ 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] The Zope Book
On Apr 8, 2005 5:59 PM, Paul Winkler [EMAIL PROTECTED] wrote: OK, but there should at least be a pointer to something to read for people wanting to get started with 2.8.0/Five. I haven't yet looked at any of the Five stuff. Is there at least a README? :) Sure. I don't guarantee that it's remotely relevant, however. :-) Well, the chapter-by-chapter editing is still not done. See http://plope.com/Books/zb_signup for an overview of the known tasks to be done. OK, but that's better than expected, I'd say. :) It sais Finished on a whole bunch of chapters. -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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] Persistent Objects
On Fri, Apr 08, 2005 at 12:00:45PM +0200, Lennart Regebro wrote: Is this persistent even among server restarts, or persistent per request, or persistent per session? (the answer is different for all of them, and usually, in Zope, persistent means persistent over server restarts). Ah, sorry. In this case, it's persistent for the life of the server, so we expect to re-initialize it when Zope restarts. Oh, and it'd be nice to give it a .reinit() capability too, if the user wants to refresh :) -roy ___ 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] The Zope Book
On Fri, Apr 08, 2005 at 06:06:57PM +0200, Lennart Regebro wrote: On Apr 8, 2005 5:59 PM, Paul Winkler [EMAIL PROTECTED] wrote: Well, the chapter-by-chapter editing is still not done. See http://plope.com/Books/zb_signup for an overview of the known tasks to be done. OK, but that's better than expected, I'd say. :) It sais Finished on a whole bunch of chapters. Yep! But only about half. Current stats for anyone who cares: Finished15 In Progress 12 Not Started 1 Unclaimed 4 -- Paul Winkler http://www.slinkp.com ___ 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] Persistent Objects
On Fri, Apr 08, 2005 at 11:30:23AM +0200, bruno modulix wrote: Look into Product, ZODB, and acquisition !-) Excellent. It looks like persistence may not be an issue here, actually, since I think the persistence I want -- hang around for the life of the Zope server -- is built in anyway, right? So what's a decent source these days for 'how to write a product' documentation? The Zope Developers Guide is in 2.4. -roy ___ 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] Persistent Objects
On Apr 8, 2005 6:44 PM, Roy S. Rapoport [EMAIL PROTECTED] wrote: Excellent. It looks like persistence may not be an issue here, actually, since I think the persistence I want -- hang around for the life of the Zope server -- is built in anyway, right? Yup, you would simply use the temp db for that. But for the life of the server is rather unusual... What are the objects you are doing, more specifically? So what's a decent source these days for 'how to write a product' documentation? The Zope Developers Guide is in 2.4. It hasn't changed that much. Stay clear of ZClasses and DTML. (Although, if you aren't planning to use any third-party products, you might actually want to look into using Zope3 instead, which is way cooler, but a tad more complicated to get started with). -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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] Persistent Objects
On Fri, Apr 08, 2005 at 06:48:49PM +0200, Lennart Regebro wrote: But for the life of the server is rather unusual... What are the objects you are doing, more specifically? We're porting a web application to manage a collection of DNS and DHCP servers. At startup time, we talk to each of these DNS and DHCP servers to ask them what zones they know about (in the case of the DNS servers) and what pools of addresses they use (in the case of the DHCP servers). This information changes rarely, and costs some time to acquire. Actually having said this just now, I'd say a better solution for us would be to actually initialize an object when the user logs in -- we can tolerate that delay, and that gives us a relatively fresh snapshot of the current situation. Don't know how that changes things. It feels like it should make it easier. (Although, if you aren't planning to use any third-party products, you might actually want to look into using Zope3 instead, which is way cooler, but a tad more complicated to get started with). Hmm. I'd be willing to use Z3, I think -- I haven't done Zope development for about 6-9 months, but all my previous experience has been on 2.x. The other people involved in this are all brand new to Zope. Why should I use Z3? Does it have better documentation? :) -roy ___ 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] Persistent Objects
On Apr 8, 2005 6:55 PM, Roy S. Rapoport [EMAIL PROTECTED] wrote: Actually having said this just now, I'd say a better solution for us would be to actually initialize an object when the user logs in -- we can tolerate that delay, and that gives us a relatively fresh snapshot of the current situation. Don't know how that changes things. It feels like it should make it easier. Yes, and no. In that case I would just store the information as usual in the ZODB, that is, the data is persistent across server restarts, but call a method that updates it when you log in (or simply have a button to do it). But the difference is rather small, since yo just call the methods at different times, and store the information in different places. Hmm. I'd be willing to use Z3, I think -- I haven't done Zope development for about 6-9 months, but all my previous experience has been on 2.x. The other people involved in this are all brand new to Zope. Why should I use Z3? Does it have better documentation? :) Actually, it does, :) But mainly, it solves a lot of things that were problematic with Zope. All development is (currently, this will change) done on the file system, no more tricky Python Scripts for example. It also allows you to do more things in pure Python, and then wrap it in Zope configuration stuff. That makes test driven development easier, and also reusing pure python stuff gets easier. Read a bit about it, and see what you think: http://www.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/FrontPage/Zope3Book Zope2 is still good. Zope 3 is just better, in many ways, although it still lacks in third-party product support. -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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] Persistent Objects
On Fri, Apr 08, 2005 at 07:13:11PM +0200, Lennart Regebro wrote: In that case I would just store the information as usual in the ZODB, that is, the data is persistent across server restarts, but call a method that updates it when you log in (or simply have a button to do it). That works. Actually, it does, :) But mainly, it solves a lot of things that were problematic with Zope. All development is (currently, this will change) done on the file system, no more tricky Python Scripts for example. Hmm. Wouldn't this allow for massively simpler integration with CVS, then? It also allows you to do more things in pure Python, and then wrap it in Zope configuration stuff. That makes test driven development easier, and also reusing pure python stuff gets easier. Nifty! Read a bit about it, and see what you think: http://www.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/FrontPage/Zope3Book Zope2 is still good. Zope 3 is just better, in many ways, although it still lacks in third-party product support. I'm a bit concerned about my perception of Zope 3's flux. I was especially dismayed to see, in the Z3 book, --- Zope 3 will come with an advanced ZODB to Filesystem synchronization tool, similar to CVS. This will allow people to make local copies of their sites work on it and check in the changes and much more. This recipe will explain how to effectively use this tool. Note: This chapter will not be included in the first version of the book, since Zope X3 3.0.0 will not ship with it and it is not actively maintained at this point. --- The first paragraph was great. The second wasn't :) -roy ___ 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] Re: ZPT and attributes
Hi Antonio, Hi all: How I can create attribute names dynamically? tal:attributes=attributename expression Sorry, I haven't explain the problem correctly :) The problem is the number of refX depends on the list of urls, i.e. if I have ['http://foo', 'http://boo', 'http://google.com'] then I create: books ref1='http://foo' ref2='http://boo' ref3='http://google.com' but with ['http://foo'] I create: books ref1='http://foo' How I create refX? Greetings. For example, I want something like this: books tal:attributes=ref1 string:http://boo;; ref2 request/URL3 / And so on. I think you are using zpt for the wrong thing. For me it seems that what you should use would be a xml product like ParsedXML. I haven't used it, but I have taken a look at the source code of Silva and saw that it may be possible to create dynamic attributes with a setAttribute or some thing like that. Regards, Josef ___ 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] Persistent Objects
On Apr 8, 2005 7:26 PM, Roy S. Rapoport [EMAIL PROTECTED] wrote: Hmm. Wouldn't this allow for massively simpler integration with CVS, then? It does yes. But developing on the file system only is possoble with Zope2 as well, of course, so theres not actual difference there. However, typically with Zope2 you end up using CMF as well, and although scripts and ZPTs are stored on the filesystem there, CMF treats them as if they are not, and hence you have security restrictions, which means you have to use restricted python, and then you have to trick yourself around that, and so on forever... ;-) Easier to just have plain Python all the way. I'm a bit concerned about my perception of Zope 3's flux. I was especially dismayed to see, in the Z3 book, --- Zope 3 will come with an advanced ZODB to Filesystem synchronization tool, similar to CVS. This will allow people to make local copies of their sites work on it and check in the changes and much more. This recipe will explain how to effectively use this tool. Note: This chapter will not be included in the first version of the book, since Zope X3 3.0.0 will not ship with it and it is not actively maintained at this point. --- The first paragraph was great. The second wasn't :) Well, that was all a part of the ideas they had for through-the-web development, and that was put on hold to implement other stuff. With file-system development only, you don't need it. :) -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ 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] The Zope Book
On Friday 08 April 2005 11:22, Paul Winkler wrote: The primary problem with the Zope Book is still the relative scarcity of resources (i.e. editors with time to work on it). The secondary problem with the Zope Book is that it's showing its age: the choice and organization of topics is IMHO less than ideal, but that can't be sufficiently addressed on a chapter-by-chapter basis, one needs to have a good overview of the whole project. This vastly increases the scope of the task. Note that my Zope 3 book is published under CC license. I could ask SAMS whether it would be okay to include parts (with proper reference and copyright notice) in the online version of the Zope 2 book. That will not document Five, but some of the component architecture. Regards, Stephan -- Stephan Richter CBU Physics Chemistry (B.S.) / Tufts Physics (Ph.D. student) Web2k - Web Software Design, Development and Training ___ 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] Windows compile Zope 2.8?
Hi List, I notice that the latest Zope does not have a Windows binary release yet (zope 2.80 alpha 2). I found an old Visual C 6.0 (still in the box!) and wonder if there are instructions somewhere that I can follow to create my own binary on Windows XP? Thanks, David ps - Maybe I'm having a bad goggling day but couldnt find something useful. I did see that Visual C is used often for this. ___ 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] Re: Windows compile Zope 2.8?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 David H wrote: Hi List, I notice that the latest Zope does not have a Windows binary release yet (zope 2.80 alpha 2). I found an old Visual C 6.0 (still in the box!) and wonder if there are instructions somewhere that I can follow to create my own binary on Windows XP? Assuming that VC6 is the compiler used to build Python (should be true for Python 2.4): C:\Zope-2.8.0a2 python.exe setup.py build_ext --inplace Tres. - -- === Tres Seaver[EMAIL PROTECTED] Zope Corporation Zope Dealers http://www.zope.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.5 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFCVvN+GqWXf00rNCgRAvg9AJ9a1ytUMxwVSml+yHvdtjYgjqhriwCeJXzw 3P5CwSXbsx5BXgCmKcas96c= =PVot -END 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 )
Re: [Zope] ExtFile Extention Mappings
Hi, Have you had a look at the Config.py file? I believe you can change the settings there so that the Zope filenames are preserved including the extensions. More specifically, I am referring to the following section in Config.py: section # repository file extension handling ZOPEID = 0 # use ZOPEID (even if it doesn't include an extension) MIMETYPE_APPEND = 1 # append extension to ZOPEID according to mimetype MIMETYPE_REPLACE = 2# remove extension from ZOPEID, then append mime extension REPOSITORY_EXTENSIONS = MIMETYPE_REPLACE /section Thanks. Satchit Edward Pollard wrote: In our quest to replace the not-quite-working External File product, we're looking at ExtFile. However, when I upload files into an ExtFile, file extensions on the file system are being changed. test1.txt becomes test1.ksh, test2.doc becomes test2.dot. They have the correct ID's in the ZMI, but on the file system they now have something quite new. Our solution relies on accessing via the ZMI and the file system at the same time, so the name being changed is somewhat inconvenient in its unpredictability (and I think Apaches mime types will get nicely screwed if we start bypassing Zope to get at them). I've done some poking at the source code but don't see why ExtFile is doing this or what logic it uses. I bet someone out there knows. --- Edward J. Pollard, B.Sc Webmaster, University of Lethbridge Ext. 1828 ___ 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 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-Checkins] SVN: Zope/branches/ajung-epi-integration/ Trying to marry PathIndex with ExtendedPathindex
Log message for revision 29908: Trying to marry PathIndex with ExtendedPathindex Changed: A Zope/branches/ajung-epi-integration/ -=- Copied: Zope/branches/ajung-epi-integration (from rev 29907, Zope/trunk) ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins
[Zope-Checkins] SVN: Zope/branches/ajung-epi-integration/ removed
Log message for revision 29916: removed Changed: D Zope/branches/ajung-epi-integration/ -=- ___ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins
Re: [Zope-dev] To ZCML or not ;-)
Lennart Regebro wrote: You know the feeling when a third party product has the wrong permission or no permission at all on something? What are you gonna do? Subclass: Lots of work. Patch: You gotta keep it updated. With ZCML, you override it. TADA! Yes, this is all stuff I know and love about Z3 ;-) When I last saw ZCML, it was horrible though. I don't mind XML, just not if it lots of pointless typing... Jim suggests that ZCML has got better, I hope so, in which case I won't have to write an alternative that uses the same underlying infrastructure :-D cheers, Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] Turning off product installation in zope.conf on all zeo clients?
Hi, There's an option to turn off prudct installation in zope.conf. What happens if you turn this off in all zeo clients? cheers, Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] To ZCML or not ;-)
Chris Withers wrote: Lennart Regebro wrote: You know the feeling when a third party product has the wrong permission or no permission at all on something? What are you gonna do? Subclass: Lots of work. Patch: You gotta keep it updated. With ZCML, you override it. TADA! Yes, this is all stuff I know and love about Z3 ;-) When I last saw ZCML, it was horrible though. I don't mind XML, just not if it lots of pointless typing... Jim suggests that ZCML has got better, I hope so, in which case I won't have to write an alternative that uses the same underlying infrastructure :-D Since ZML is XML, creating a less verbose language may be easier to accomplish by actually *using* the XML infrastructure, and translating your language to ZCML. Anyway, while I have my criticisms of ZCML, too much typing is really not very important in my list. You can get it somewhat shorter, I'm sure, but not *that* much shorter. I'd worry more about the reading part than the writing. Regards, Martijn ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] Turning off product installation in zope.conf on all zeo clients?
On Apr 8, 2005, at 11:00, Chris Withers wrote: Hi, There's an option to turn off prudct installation in zope.conf. What happens if you turn this off in all zeo clients? New products don't get installed..? jens ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] To ZCML or not ;-)
On Apr 8, 2005 12:54 PM, Martijn Faassen [EMAIL PROTECTED] wrote: Chris Withers wrote: Lennart Regebro wrote: You know the feeling when a third party product has the wrong permission or no permission at all on something? What are you gonna do? Subclass: Lots of work. Patch: You gotta keep it updated. With ZCML, you override it. TADA! Yes, this is all stuff I know and love about Z3 ;-) When I last saw ZCML, it was horrible though. I don't mind XML, just not if it lots of pointless typing... Jim suggests that ZCML has got better, I hope so, in which case I won't have to write an alternative that uses the same underlying infrastructure :-D Since ZML is XML, creating a less verbose language may be easier to accomplish by actually *using* the XML infrastructure, and translating your language to ZCML. Anyway, while I have my criticisms of ZCML, too much typing is really not very important in my list. You can get it somewhat shorter, I'm sure, but not *that* much shorter. I'd worry more about the reading part than the writing. Yeah, I mean: something:something foo=bar frotz=fnyppel fingal:ohlsson bitbucket=buccaneer / /something:something Is not significantly shorter than: something/something: foo=bar frotz=fnyppel fingal/ohlsson: bitbucket=buccaneer Which would be really a minimal/shortest way to write it. For me, the main drawback with ZCML is that WingIDE doesn't to auto completion on it. ;) An ZCML editor that automatically popped up a list of the supported keywords for every statement would be really nice. :-p A benefit of using an XML format is that many editors will happily both do syntax high-lighting, some sort of auto-indentation, and automatic commenting/uncommenting. A non-standard syntax wouldn't do that. -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] To ZCML or not ;-)
Lennart Regebro wrote: On Apr 8, 2005 12:54 PM, Martijn Faassen [EMAIL PROTECTED] wrote: ... A benefit of using an XML format is that many editors will happily both do syntax high-lighting, some sort of auto-indentation, and automatic commenting/uncommenting. A non-standard syntax wouldn't do that. Speaking of which, a nice little project for someone would be to write a generator to generate RelaxNG schemas from ZCML meta configuration. Then XML editors could provide more help with the editing, possibly including hings like autocompletion. This should be a realtively easy task in that apidoc already has code for extracting documentation from meta configuration. Jim -- Jim Fulton mailto:[EMAIL PROTECTED] Python Powered! CTO (540) 361-1714http://www.python.org Zope Corporation http://www.zope.com http://www.zope.org ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] To ZCML or not ;-)
On Friday 08 April 2005 03:24, Chris Withers wrote: Yes, this is all stuff I know and love about Z3 ;-);-) When I last saw ZCML, it was horrible though. I don't mind XML, just not if it lots of pointless typing... Can you be more specific? I think ZCML is very compact. Regards, Stephan -- Stephan Richter CBU Physics Chemistry (B.S.) / Tufts Physics (Ph.D. student) Web2k - Web Software Design, Development and Training ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] To ZCML or not ;-)
On Friday 08 April 2005 07:34, Lennart Regebro wrote: For me, the main drawback with ZCML is that WingIDE doesn't to auto completion on it. ;) An ZCML editor that automatically popped up a list of the supported keywords for every statement would be really nice. :-p: Yeah, I talked to Stephan and John about that already. Using Wing's new plugin architecture, it should be possible to insert such functionality. Another good application for the plugin system would be the recognition of interfaces by showing the interface documentation of a class implementing a certain interface. Regards, Stephan -- Stephan Richter CBU Physics Chemistry (B.S.) / Tufts Physics (Ph.D. student) Web2k - Web Software Design, Development and Training ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] Re: [Zope 2.8] Inclusion of ExtendedPathIndex?
--On Donnerstag, 7. April 2005 8:00 Uhr -0400 Tres Seaver [EMAIL PROTECTED] wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Andreas Jung wrote: I wonder if it is of public interest to include the ExtendedPathIndex from Plone in Zope 2.8. It offers some the nice extension to limit the depth of the search and improves building navigation-trees or similar structures. Opinions? I doubt many folks on this list know the code that well. Are you thinking to lift the features you mention, making them part of the regular PathIndex? I succeeded in merging the ExtendedPathIndex code with the existing PathIndex code without changing the existing behaviour (means all original tests + the new tests) pass. Andreas pgpzfM5WuKiur.pgp Description: PGP signature ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] To ZCML or not ;-)
On Apr 8, 2005 3:09 PM, Stephan Richter [EMAIL PROTECTED] wrote: On Friday 08 April 2005 07:34, Lennart Regebro wrote: For me, the main drawback with ZCML is that WingIDE doesn't to auto completion on it. ;) An ZCML editor that automatically popped up a list of the supported keywords for every statement would be really nice. :-p: Yeah, I talked to Stephan and John about that already. Using Wing's new plugin architecture, it should be possible to insert such functionality. Another good application for the plugin system would be the recognition of interfaces by showing the interface documentation of a class implementing a certain interface. Cool, that's good news. I won't have time to do it for the forseeable future though... -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/ ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] To ZCML or not ;-)
Lennart Regebro wrote: [snip] For me, the main drawback with ZCML is that WingIDE doesn't to auto completion on it. ;) An ZCML editor that automatically popped up a list of the supported keywords for every statement would be really nice. :-p Actually emacs + nxml + the Relax NG schema (unfortunately out of date; it should be autogenerated from the code) for ZCML does that. A benefit of using an XML format is that many editors will happily both do syntax high-lighting, some sort of auto-indentation, and automatic commenting/uncommenting. A non-standard syntax wouldn't do that. Yup, and if you use some XML editor (or an XML editor extension for your favorite editor) it can do quite sophisticated schema-driven stuff. Regards, Martijn ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] Re: ZPT: defer expression fix
Evan Simpson wrote: Christian Heimes wrote: That's an interessting use case. Do you want me to keep the code and make up a new expression? I'm thinking about lazy:. If you have a particular use for defer: that would justify the split, please go ahead. I have no particular interest in keeping it. I left defer: like it was coded by you and added a new expression lazy: that is working like a lazy initialization variable. Christian ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] Re: ZPT: defer expression fix
Tres Seaver wrote: I'd be glad to help with that, Christian. I've added a doc string to the DeferExpr module. Do you want me to write more docs is it enough to be added to the ZPT guide? Also I need a little help for the unit tests. How can I emulate tal:content or similar inside an expression test? Except of some missing unit tests the branch is ready to merge. I would like to get the changes into Zope 2.7.6 so we could use them for Plone 2.1.0. Christian ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] debug-mode on under Windows 2000.
Zope Version: (Zope 2.7.3-0, python 2.3.4, win32) Python Version: 2.3.4 (#53, May 25 2004, 21:17:02) [MSC v.1200 32 bit (Intel)] System Platform: Windows 2000 I'm trying to get Zope to reload my Python modules so I don't have to restart Zope after code changes. Even with debug-mode on (according to the zope config file, it defaults to on) my modules are not being reloaded unless I do a restart. Is there a fix for this? Thanks, Don ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-DB] Null characters booleans
On 2005-04-08 at 10:44:59 [+0200], Andrew Veitch [EMAIL PROTECTED] wrote: We'd be willing to provide patches for both these issues if there's interest and agreement it's a sensible way to go. The most sensible thing is if the DA does not have to do the quoting at all and that this is either done by the underlying Python driver or better still by the database. This is significantly faster and safer. If you use our mxODBCZopeDA as an ExternalMethod you can use bound parameters (have your cake and eat it). We started some work on a replacement last year after EuroPython and you can check the archives for our progress. My cycling accident interrupted work :-/ but I'm starting to look at using SimpleTemplates in conjunction with a considerably simplified DB.py which will do little more than call the .execute() on the connection. Charlie ___ Zope-DB mailing list Zope-DB@zope.org http://mail.zope.org/mailman/listinfo/zope-db
Re: [Zope-DB] Creating a hyperlink using results from query
On 2005-04-08 at 11:44:17 [+0200], Martin Jennings [EMAIL PROTECTED] wrote: Firstly, thank you to those who answered by query on the empty result set, it set me on the way to finding a solution. Not sure if this is the right list to ask on, but here is the question. I have got information from a ZSQL request in a result set and I want to use one of the values as a parameter in a hyperlink, how do I do this? I.e. a href=htmlPage?parameter=ZSQLValuemy linka How do I write the code for this? Thank you in advance, and once again, sorry if this is not the correct list. Hi Martin, read up on doing this with PageTemplates. You need to use the TALES keyword attributes Something similar to block tal:repeat=result myQuery a tal:attributes=href result/link tal:content=result/value/a /block is what you want. Charlie -- Charlie Clark eGenix.com Professional Python Services directly from the Source Python/Zope Consulting and Support ...http://www.egenix.com/ mxODBC.Zope.Database.Adapter ... http://zope.egenix.com/ mxODBC, mxDateTime, mxTextTools ...http://python.egenix.com/ ::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,FreeBSD for free ! ___ Zope-DB mailing list Zope-DB@zope.org http://mail.zope.org/mailman/listinfo/zope-db
Re: [Zope-DB] Returning values from Oracle function/procedure withZSQLMethod
Quoting Jim Abramson [EMAIL PROTECTED]: In our experience we ended up needing to do increasingly complex things with plsql, and ultimately, we had no choice to move all our db access out into ExternalMethods or Products and use DCOracle2 directly. This does require constructing your own connection pool/management, but once you've built that you can leverage DCOracle2 directly in python and this provides much more flexibility. When you do our own connection management, are you able to avoid DCOracle2 leaking connections? In our Zope 2.6.1/DCOracle2-1.3b server, we accumulate sessions where Oracle is waiting for a response from Zope, but Zope apparently thinks it closed that connection and opened a new one. Manually closing and reopening the connection does not clean up the forgotten sessions, so I periodically (~monthly) restart the Zope server to clean up. Killing the Zope processes seems to finally signal Oracle (on a remote machine) that the client is no longer interested in those old open sessions. The smidge of testing I did with DCOracle2 from the command line left me with the impression that its connection closing function did not work. I could close a connection - and then still use it to talk to my database. I wasn't really sure enough of those tests to report this as a bug, but it is vaguely troubling. -- Cynthia Kiser ___ Zope-DB mailing list Zope-DB@zope.org http://mail.zope.org/mailman/listinfo/zope-db
[Zope-DB] UnpicklingError in Ape 1.0
Hi all, I had a problem when trying to use Ape 1.0 in Zope 2.7 to store data in MySQL database. I cannot add objects into the mount point portion (default is '/sql'). Here is the trace back I found in log file: 2005-04-06T15:12:01 INFO(0) ZODB conflict error at /sql/manage_addProduct/OFSP/manage_addImage (1 conflicts since startup at 2005-04-06T15:08:45) -- 2005-04-06T15:12:02 ERROR(200) ZODB Couldn't load state for '5' Traceback (most recent call last): File C:\TestSites\APE\Products\Ape\lib\apelib\zodb3\connection.py, line 359, in setstate event = osio.deserialize(oid, obj, classification, state) File C:\TestSites\APE\Products\Ape\lib\apelib\core\io.py, line 160, in deserialize mapper.serializer.deserialize(event, state) File C:\TestSites\APE\Products\Ape\lib\apelib\core\serializers.py, line 121, in deserialize s.deserialize(event, state) File C:\TestSites\APE\Products\Ape\lib\apelib\zodb3\serializers.py, line 291, in deserialize s = u.load() UnpicklingError: unpickling stack underflow I have no idea why. Everything works fine with filesystem storage. Could anyone help?! Thanks, Dtvie ___ Zope-DB mailing list Zope-DB@zope.org http://mail.zope.org/mailman/listinfo/zope-db