Re: [Zope] Problem with adding items to ZClass instance
I discovered something bizarre that happens in my 2.1.4 and 2.2b1 installations.
Bizarre, yes, unusual, no.
I have a ZClass based on ObjectManager. In an instance of the ZClass, I can "Add" most of the available objects (DTML Documents, DTML Methods, User Folder, MailHost to name a few). However, for at least two items (TinyTable and ZMySQL DB Connection), when I add them, they show up in the container folder, not in the ZClass instance. Then, if I check it to delete it, it gives a "does not exist" error. Upon refreshing the container folder, the item still shows, but then I *can* delete it. Equally interesting is that I can Copy the item from the container folder and successfully Paste it into the ZClass instance. However, since ZMySQL DB Connections don't support Copy/Paste, that won't work.
What's going on? Is it a problem with my ZClass, the Product manage_add, or Zope? Or me?
This is not so easy to answer. ZClasses do strange things to adding items. If your ZCLass definition (in the Product) is nested in another ZClass, then it is your ZClass. If the ZClass definition is defined in the top level of your product. There may be other things going on, including all of the above ;-) You'll need to provide more details to be able to say more about this. hth Rik
On Sun, 18 Jun 2000, Rik Hoekstra wrote:
This is not so easy to answer. ZClasses do strange things to adding items. If your ZCLass definition (in the Product) is nested in another ZClass, then it is your ZClass. If the ZClass definition is defined in the top level of your product. There may be other things going on, including all of the above ;-) You'll need to provide more details to be able to say more about this.
I'm not sure what kind of information would help. Let me know what and I'll be happy to provide it. I'll provide the Product .zexp which includes a single top-level ZClass, a couple dozen methods and a single property sheet, if that would help. There's nothing especially complex about it. It uses ZSQLMethods (w/ MySQLDA) and TinyTables, and once I can get the stuff in the right place in the instance, everything works just fine. Thanks! --- Ron
Ron Bickers wrote:
On Sun, 18 Jun 2000, Rik Hoekstra wrote:
This is not so easy to answer. ZClasses do strange things to adding items. If your ZCLass definition (in the Product) is nested in another ZClass, then it is your ZClass. If the ZClass definition is defined in the top level of your product. There may be other things going on, including all of the above ;-) You'll need to provide more details to be able to say more about this.
I'm not sure what kind of information would help. Let me know what and I'll be happy to provide it. I'll provide the Product .zexp which includes a single top-level ZClass, a couple dozen methods and a single property sheet, if that would help. There's nothing especially complex about it. It uses ZSQLMethods (w/ MySQLDA) and TinyTables, and once I can get the stuff in the right place in the instance, everything works just fine.
Hm, this is getting hard to answer. Adding normal instances of ZCLasses to other ZClasses should work. Are you adding everything straight from the management interface or programmatically from DTML? If from the management interface, are you sure you always add TinyTable etc from within the instance? If programmatically, could you send the code? Perhaps you could try and adding one of the problem products in another way (from a dtml method instead of the management interface or the other way around). Rik
-----Original Message----- From: Rik Hoekstra [mailto:rik.hoekstra@inghist.nl] Sent: Monday, June 19, 2000 6:23 AM To: Ron Bickers Cc: zope@zope.org Subject: Re: [Zope] Problem with adding items to ZClass instance
Hm, this is getting hard to answer. Adding normal instances of ZCLasses to other ZClasses should work. Are you adding everything straight from the management interface or programmatically from DTML? If from the management interface, are you sure you always add TinyTable etc from within the instance? If programmatically, could you send the code?
Perhaps you could try and adding one of the problem products in another way (from a dtml method instead of the management interface or the other way around).
The items I'm adding aren't other ZClasses, but rather from python products. I haven't come up with an exhaustive list of which items cause the problem and which don't, but I know at least the TinyTable and ZMySQL DB Connection do, and the DTML Methods/Documents, MailHost and UserFolders don't. Everything is being added via the interface. I haven't tried adding them via DTML. I've never done that because I haven't had a use for it, so I'm not sure I know how. I setup a series of screen shots to demonstrate exactly what's happening. Take a look at http://www.logicetc.com/Test/zclass_problem if you're interested. Thanks! _______________________ Ron Bickers Logic Etc, Inc. rbickers@logicetc.com
participants (2)
-
Rik Hoekstra -
Ron Bickers