AW: [Zope3-dev] apidoc is crowling outside my Zope3 root?
Dmitry Vasiliev
lists at hlabs.spb.ru
Fri Apr 2 07:12:21 EST 2004
Roger ineichen wrote:
> Thanks
>
> I think it was my(configuration) problem of getting the wrong python.
> After installing Plone 2 apidoc was using the Python (expathreader)
> of the plone installation.
> The PYTHONPATH is correct and don't include this Plone Python version.
> I don't know how this could crawl my Plone in a different folder.
> I explicit start the Zope3 with a fresh 2.3.3 Py like:
> c:\Python23\python.exe z3.py
> Perhaps this has something to do with dll's and I was using a wrong dll
> after installing Plone???
>
> I uninstalled Plone and then a py23.dll was missing.
>
> After installing a fesh py 2.3.3, I get another ERROR, see below.
>
> If I exclude apidoc from the configure.zcml Zope3 ist starting ok.
>
>
> C:\projektCompiler\current>c:\Python23\python.exe z3.py
> Traceback (most recent call last):
> File "z3.py", line 65, in ?
> run()
> File "z3.py", line 61, in run
> main(argv[1:])
> File "C:\projektCompiler\current\src\zope\app\process\main.py", line 56,
> in main
> setup(args)
> File "C:\projektCompiler\current\src\zope\app\process\main.py", line 89,
> in setup
> config(options.site_definition)
> File "C:\projektCompiler\current\src\zope\app\_app.py", line 43, in config
> context = xmlconfig.file(file, execute=execute)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 449, in file
> include(context, name, package)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 376, in include
> processxmlfile(f, context)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 244, in processxmlfile
> parser.parse(src)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 109, in parse
> xmlreader.IncrementalParser.parse(self, source)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\xmlreader.py", line 123,
> in parse
> self.feed(buffer)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 216, in feed
> self._parser.Parse(data, isFinal)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 364, in end_element_ns
> self._cont_handler.endElementNS(pair, None)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 224, in endElementNS
> self.context.end()
> File "C:\projektCompiler\current\src\zope\configuration\config.py", line
> 476, in end
> self.stack.pop().finish()
> File "C:\projektCompiler\current\src\zope\configuration\config.py", line
> 623, in finish
> actions = self.handler(context, **args)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 376, in include
> processxmlfile(f, context)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 244, in processxmlfile
> parser.parse(src)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 109, in parse
> xmlreader.IncrementalParser.parse(self, source)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\xmlreader.py", line 123,
> in parse
> self.feed(buffer)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 216, in feed
> self._parser.Parse(data, isFinal)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 364, in end_element_ns
> self._cont_handler.endElementNS(pair, None)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 224, in endElementNS
> self.context.end()
> File "C:\projektCompiler\current\src\zope\configuration\config.py", line
> 476, in end
> self.stack.pop().finish()
> File "C:\projektCompiler\current\src\zope\configuration\config.py", line
> 623, in finish
> actions = self.handler(context, **args)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 376, in include
> processxmlfile(f, context)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 244, in processxmlfile
> parser.parse(src)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 109, in parse
> xmlreader.IncrementalParser.parse(self, source)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\xmlreader.py", line 123,
> in parse
> self.feed(buffer)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 216, in feed
> self._parser.Parse(data, isFinal)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 364, in end_element_ns
> self._cont_handler.endElementNS(pair, None)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 224, in endElementNS
> self.context.end()
> File "C:\projektCompiler\current\src\zope\configuration\config.py", line
> 476, in end
> self.stack.pop().finish()
> File "C:\projektCompiler\current\src\zope\configuration\config.py", line
> 623, in finish
> actions = self.handler(context, **args)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 376, in include
> processxmlfile(f, context)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 244, in processxmlfile
> parser.parse(src)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 109, in parse
> xmlreader.IncrementalParser.parse(self, source)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\xmlreader.py", line 123,
> in parse
> self.feed(buffer)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 216, in feed
> self._parser.Parse(data, isFinal)
> File "c:\Python23\lib\site-packages\_xmlplus\sax\expatreader.py", line
> 364, in end_element_ns
> self._cont_handler.endElementNS(pair, None)
> File "C:\projektCompiler\current\src\zope\configuration\xmlconfig.py",
> line 224, in endElementNS
> self.context.end()
> File "C:\projektCompiler\current\src\zope\configuration\config.py", line
> 476, in end
> self.stack.pop().finish()
> File "C:\projektCompiler\current\src\zope\configuration\config.py", line
> 623, in finish
> actions = self.handler(context, **args)
> File "C:\projektCompiler\current\src\zope\app\component\metaconfigure.py",
> line 183, in utility
> component = factory()
> File
> "C:\projektCompiler\current\src\zope\app\apidoc\classmodule\__init__.py",
> line 539, in __init__
> self.__setup()
> File
> "C:\projektCompiler\current\src\zope\app\apidoc\classmodule\__init__.py",
> line 544, in __setup
> self._Module__children[name] = Module(self, name, safe_import(name))
> File
> "C:\projektCompiler\current\src\zope\app\apidoc\classmodule\__init__.py",
> line 185, in __init__
> self.__setup()
> File
> "C:\projektCompiler\current\src\zope\app\apidoc\classmodule\__init__.py",
> line 214, in __setup
> for name in self.__module.__dict__.keys():
> zope.configuration.xmlconfig.ZopeXMLConfigurationError: File
> "C:\projektCompiler\current\site.zcml", line 3.2-3.32
> ZopeXMLConfigurationError: File
> "C:\projektCompiler\current\src\zope\app\configure.zcml", line 122.2-122.39
> ZopeXMLConfigurationError: File
> "C:\projektCompiler\current\src\zope\app\apidoc\configure.zcml", line
> 19.2-19.36
> ZopeXMLConfigurationError: File
> "C:\projektCompiler\current\src\zope\app\apidoc\classmodule\configure.zcml",
> line 23.2-26.19
> AttributeError: 'NoneType' object has no attribute '__dict__'
The problem is that 'app.apidoc.classmodule.ClassModule' can't import
'Mount.py' which is mentioned in the ClassModule.rootModules.
Seems like a bug for me... There is a quick patch:
------------------------------------------------------------------
Index: __init__.py
===================================================================
RCS file:
/cvs-repository/Zope3/src/zope/app/apidoc/classmodule/__init__.py,v
retrieving revision 1.7
diff -u -r1.7 __init__.py
--- __init__.py 2 Apr 2004 01:45:07 -0000 1.7
+++ __init__.py 2 Apr 2004 08:04:03 -0000
@@ -531,7 +531,7 @@
"""
rootModules = ['ZConfig', 'ZODB', 'persistence', 'transaction',
'zdaemon',
- 'zope', 'Mount.py']
+ 'zope']
def __init__(self):
"""Initialize object."""
-------------------------------------------------------------------
--
Dmitry Vasiliev (dima at hlabs.spb.ru)
http://hlabs.spb.ru
More information about the Zope3-dev
mailing list