Hello, i've got the following error while trying to import something, has anybody an idea about the reason? I tried to import a .zexp (deep structure with ~ 300MB). The folder-id i tried to import currently doesn't exist. thanks for your help! regards, J. Walte TypeError Traceback (innermost last): File /home/xiteflex130/lib/python/ZPublisher/Publish.py, line 150, in publish_module File /home/xiteflex130/lib/python/ZPublisher/Publish.py, line 114, in publish File /home/xiteflex130/lib/python/Zope/__init__.py, line 159, in zpublisher_exception_hook (Object: xiteflex root folder) File /home/xiteflex130/lib/python/ZPublisher/Publish.py, line 98, in publish File /home/xiteflex130/lib/python/ZPublisher/mapply.py, line 88, in mapply (Object: manage_importObject) File /home/xiteflex130/lib/python/ZPublisher/Publish.py, line 39, in call_object (Object: manage_importObject) File /home/xiteflex130/lib/python/OFS/ObjectManager.py, line 526, in manage_importObject (Object: xiteflex root folder) File /home/xiteflex130/lib/python/OFS/ObjectManager.py, line 542, in _importObjectFromFile (Object: xiteflex root folder) File /home/xiteflex130/lib/python/ZODB/ExportImport.py, line 79, in importFile File /home/xiteflex130/lib/python/ZODB/Transaction.py, line 234, in commit File /home/xiteflex130/lib/python/ZODB/Connection.py, line 235, in commit File /home/xiteflex130/lib/python/ZODB/ExportImport.py, line 148, in _importDuringCommit TypeError: __import__() argument 1 must be string without null bytes, not string
<snip> ----- Original Message ----- From: jens.walte@kk.net i've got the following error while trying to import something, has anybody an idea about the reason? I tried to import a .zexp (deep structure with ~ 300MB). The folder-id i tried to import currently doesn't exist. TypeError Traceback (innermost last): File /home/xiteflex130/lib/python/ZPublisher/Publish.py, line 150, in publish_module File /home/xiteflex130/lib/python/ZPublisher/Publish.py, line 114, in publish File /home/xiteflex130/lib/python/Zope/__init__.py, line 159, in zpublisher_exception_hook (Object: xiteflex root folder) File /home/xiteflex130/lib/python/ZPublisher/Publish.py, line 98, in publish File /home/xiteflex130/lib/python/ZPublisher/mapply.py, line 88, in mapply (Object: manage_importObject) File /home/xiteflex130/lib/python/ZPublisher/Publish.py, line 39, in call_object (Object: manage_importObject) File /home/xiteflex130/lib/python/OFS/ObjectManager.py, line 526, in manage_importObject (Object: xiteflex root folder) File /home/xiteflex130/lib/python/OFS/ObjectManager.py, line 542, in _importObjectFromFile (Object: xiteflex root folder) File /home/xiteflex130/lib/python/ZODB/ExportImport.py, line 79, in importFile File /home/xiteflex130/lib/python/ZODB/Transaction.py, line 234, in commit File /home/xiteflex130/lib/python/ZODB/Connection.py, line 235, in commit File /home/xiteflex130/lib/python/ZODB/ExportImport.py, line 148, in _importDuringCommit TypeError: __import__() argument 1 must be string without null bytes, not string </snip> I don't know about the error message, but whenever I have had problems with importing a .zexp file is has to do with the either the ownership or priviledges assigned to the zexp file (which can be changed during a copy/move process). In linux, this can be fixed with: chown, chgrp and chmod. HTH Jonathan _______________________________________________ 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 )
Jonathan Hobbs wrote at 2004-9-21 08:21 -0400:
... File /home/xiteflex130/lib/python/ZODB/ExportImport.py, line 148, in _importDuringCommit TypeError: __import__() argument 1 must be string without null bytes, not string
Looks like your "zexp" is corrupt. The builtin function "__import__" is called and it complains that its first argument (the name of the module to be imported) contains null bytes. Definitely, module names should not contain null bytes... -- Dieter
participants (3)
-
Dieter Maurer -
jens.walte@kk.net -
Jonathan Hobbs