[Zope-dev] .zexp's

2001-04-22 Thread Zopista
Just ran into a problem with a newbie where they couldnt figure out where to import the zexp, if its a product it should go in /Control_Panel/Products, if not it should go in the ZODB. I couldn't think of an obvious way to tell, so I just had a look in the zexp and came up with this: file = open(

Re: [Zope-dev] ZPatterns AttributeProvider question

2001-04-22 Thread Christian Scholz
Hi! Just a quick note as it's quite late already (more tomorrow): > In the early days of ZPatterns, I assumed that I would create SQL > providers, LDAP providers, and suchlike gizmos. Later, it became clear > that it was more useful to have a simple "glue" language to allow > harnessing the ful

Re: [Zope-dev] ZPatterns AttributeProvider question

2001-04-22 Thread Phillip J. Eby
At 08:29 PM 4/22/01 +0200, Christian Scholz wrote: >Hi! > >A little update.. > >Actually I was mistaken and SetAttributeFor() is called. Just _objectChanged() >is not called in that case.. and thus my attributes are not stored to the database. When an object is newly added, only _objectAdded() is

Re: [Zope-dev] ZPatterns AttributeProvider question

2001-04-22 Thread Phillip J. Eby
At 08:29 PM 4/22/01 +0200, Christian Scholz wrote: >Hi! > >A little update.. > >Actually I was mistaken and SetAttributeFor() is called. Just _objectChanged() >is not called in that case.. and thus my attributes are not stored to the database. When an object is newly added, only _objectAdded() is

Re: [Zope-dev] "pydoc" for Zope - another great documentation finding tool

2001-04-22 Thread Dieter Maurer
Zopista writes: > Yes please, I want to integrate pydoc in to the SourceCodeBrowser which is > at zopezen.org and I'm just to about to release as a product. The (minor) modification to let "pydoc" work with Zope can be found via URL:http://www.dieter.handshake.de/pyprojects/zope/pydoc.html "

[Zope-dev] "pydoc" for Zope - another great documentation finding tool

2001-04-22 Thread Dieter Maurer
I installed Python 2.1 and checked what great new things are there: they are numerous! As you know, I am a fan of documentation - reliable documentation, if possible directly extracted from the source. Therefore, the new Python documenter "pydoc" was very attractive for me. I had to tweak "Zop

Re: [Zope-dev] ZPatterns AttributeProvider question

2001-04-22 Thread Christian Scholz
Hi! A little update.. Actually I was mistaken and SetAttributeFor() is called. Just _objectChanged() is not called in that case.. and thus my attributes are not stored to the database. Also commit() is not called at all in this case. It get's called once when the subtranscation is committed but

Re: [Zope-dev] ZPatterns AttributeProvider question

2001-04-22 Thread Steve Alexander
Phillip J. Eby wrote: > Steve Alexander wrote: > >> As a simpler workaround, you can use >>your_object.commitSubtransaction() instead of redirecting to a new page. >> > Um, this shouldn't be the issue here. _SetAttributeFor() should be called > when the attribute is set; it's not transaction

Re: [Zope-dev] ZPatterns AttributeProvider question

2001-04-22 Thread Phillip J. Eby
At 03:07 PM 4/22/01 +0100, Steve Alexander wrote: > > As a simpler workaround, you can use >your_object.commitSubtransaction() instead of redirecting to a new page. Um, this shouldn't be the issue here. _SetAttributeFor() should be called when the attribute is set; it's not transaction-drive

Re: [Zope-dev] ZPatterns AttributeProvider question

2001-04-22 Thread Steve Alexander
Christian Scholz wrote: > > So what I do now as workaround is > > dtml method 1: > > - creates new object via newItem() > - redirects to dtml method 2 > > dtml method 2: > - retrieves the newly created object with getItem() > - calls manage_changeProperties on that object > > This is working

Re: [Zope-dev] ZPatterns AttributeProvider question

2001-04-22 Thread Christian Scholz
Hi! > >Yes, as said above it registers for handlers and attributes. Also > >_objectChanged and _SetAttributeFor() etc. are called. They're just not > called > >directly after creating the object (when being in the same request that is). > > _objectChanged() is a transaction-commit message. You

Re: [Zope-dev] [] vs () in dtml-in: is this a bug ?

2001-04-22 Thread Stefane Fermigier
On Sun, Apr 22, 2001 at 01:16:57PM +0100, Steve Alexander wrote: > > If you look throughthe zope-dev list archives, you'll find a number of > arguments on each side as to whether this is a bug or a feature. Thanks. I definitely call that a bug. S. -- Stéfane Fermigier, Tel: +33 (0)

Re: [Zope-dev] [] vs () in dtml-in: is this a bug ?

2001-04-22 Thread Steve Alexander
Stefane Fermigier wrote: > Hi, > > please try this as a DTML Method: > > > > > > > > > > > > > > Why should the two results differ ? This is a designed-in feature of dtml-in. When you call an items() method on a dictionary-like object, you get back a list of two-tuple

[Zope-dev] [] vs () in dtml-in: is this a bug ?

2001-04-22 Thread Stefane Fermigier
Hi, please try this as a DTML Method: Why should the two results differ ? S. -- Stéfane Fermigier, Tel: 06 63 04 12 77 (mobile). http://nuxeo.com/ & http://portalux.com/ & http://aful.org/ "Amazon: we patent the dot in .com" __