On Tue, 17 Aug 2004 09:21:18 +0200 Chris Withers <chris@simplistix.co.uk> wrote:
Rodrigo Dias Arruda Senra wrote:
from BTreeFolder2 import BTreeFolder2
Here's your problem. On the client, you're adding BTreeFolder2.BTreeFolder2 instances. Through the ZMI you're adding Products.BTreeFolder2.BTreeFolder2 instances.
Great! Thank you Chris, changing the import statement to: 'from Products.BTreeFolder2 import BTreeFolder2' worked like a charm!
You should use zopectl run instead of your hacked up ZEO client code...
I would love too, but unfortunately everything is running in Windows XP.
Or, at a minimum:
import Zope app = Zope.startup()
I did that with the following results: """ Traceback (most recent call last): File "test_zeo.py", line 24, in ? app = Zope.startup() File "C:\Program Files\Zope-2.7.2-0\lib\python\Zope\__init__.py", line 47, in startup _startup() File "C:\Program Files\Zope-2.7.2-0\lib\python\Zope\App\startup.py", line 57, in startup DB = configuration.dbtab.getDatabase('/', is_root=1) AttributeError: 'NoneType' object has no attribute 'getDatabase' """ It seems that configuration.dbtab is None. Perhaps my code lacks additional initialization ? Meanwhile, I moved back to : app = root['Application'] #app = Zope.startup()
Rather than your own python path hacking.
Nevertheless, with your help <wink> it is working now! I'm just trying to build a valid ZEO client code (in the absence of zopectl). I have a Twisted app that pre-process datagrams and deliver the result through ZEO to Zope's web rendering machinery. But I'm always open to any bits of wisdom I can get. best regards, Senra