Re: Errors running CMFPlone/Extensions/setupSite.py with Zope 2.7

Jim Roepcke <[email protected]>
Newsgroups gmane.comp.web.zope.plone.installers
Message-ID <[email protected]>
On Sunday, December 14, 2003, at 06:16  PM, alan runyan wrote:

> I think ChrisM needs a more specific bug report.

More specific than this message sent to plone-installers last week when  
it's a known issue and supposedly there's a fix for it in CVS?

> If you try to run setupSite.py using Zope 2.7 you'll get an error:
>
>> /Applications/Plone2/Sites/Testing/Products/ 
>> PlacelessTranslationService/__init__.py:38: DeprecationWarning:  
>> Non-ASCII character '\xe1' in file  
>> /Applications/Plone2/Sites/Testing/Products/ 
>> PlacelessTranslationService/PatchStringIO.py on line 1, but no  
>> encoding declared; see http://www.python.org/peps/pep-0263.html for  
>> details
>>   import PatchStringIO
>> Traceback (most recent call last):
>>   File  
>> "/Applications/Plone2/Sites/Testing/Products/CMFPlone/Extensions/ 
>> setupSite.py", line 52, in ?
>>     process(name, swhome, ihome)
>>   File  
>> "/Applications/Plone2/Sites/Testing/Products/CMFPlone/Extensions/ 
>> setupSite.py", line 20, in process
>>     app = Zope.app()
>>   File  
>> "/Applications/Plone2/Library/Software/Zope270/Zope/lib/python/Zope/ 
>> __init__.py", line 50, in app
>>     startup()
>>   File  
>> "/Applications/Plone2/Library/Software/Zope270/Zope/lib/python/Zope/ 
>> __init__.py", line 46, in startup
>>     _startup()
>>   File  
>> "/Applications/Plone2/Library/Software/Zope270/Zope/lib/python/Zope/ 
>> App/startup.py", line 56, in startup
>>     DB = configuration.dbtab.getDatabase('/', is_root=1)
>> AttributeError: DefaultConfiguration instance has no attribute 'dbtab'
>
> See this URL for information about the above error message:
>
> 	http://mail.zope.org/pipermail/zope-dev/2003-August/020274.html
>
> I was able to manually run setupSite.py without problems using zopectl  
> debug.
>
>> [SilverSurfer:Plone2/Sites/Testing] jim%  
>> /Applications/Plone2/Sites/Testing/bin/zopectl debug
>> Starting debugger (the name "app" is bound to the top-level Zope  
>> object)
>> >>> import Products.CMFPlone.Extensions.setupSite
>> >>> Products.CMFPlone.Extensions.setupSite.process('admin',  
>> '/Applications/Plone2/Library/Software/Zope270/Zope/lib/python',  
>> '/Applications/Plone2/Sites/Testing')
>> ['Retrieved the admin user', 'Added external method', 'Set an access  
>> rule', 'Added Plone', 'Added Site Root', 'Finished']
>> >>> ^D
>
> Calling 'zopectl debug setupSite.py' doesn't do anything:
>
>> [SilverSurfer:Plone2/Sites/Testing] jim%  
>> /Applications/Plone2/Sites/Testing/bin/zopectl debug  
>> /Applications/Plone2/Sites/Testing/Products/CMFPlone/Extensions/ 
>> setupSite.py
>> Starting debugger (the name "app" is bound to the top-level Zope  
>> object)
>> >>> print app.objectValues()
>> [<UserFolder instance at 1b994d0>, <ApplicationManager instance at  
>> 1cdb350>, <SimpleTemporaryContainer instance at 1cebc80>,  
>> <BrowserIdManager instance at 1cebdd0>, <SessionDataManager instance  
>> at 1cebda0>, <SiteErrorLog at /error_log>, <DTMLMethod instance at  
>> 252c740>, <DTMLMethod instance at 252cef0>, <DTMLMethod instance at  
>> 252ce60>, <DTMLMethod instance at 252cfb0>, <ZopePageTemplate at  
>> /standard_template.pt>]
>> >>> ^D
>
> How do you recommend the installers execute setupSite.py with Zope  
> 2.7.0b3?  I suppose we could redirect some input into 'zopectl debug'  
> to simulate this but I don't know if that'll be reliable... it's a  
> disgusting hack at best.
>
> Suggestions?
>
> Jim

--
Jim Roepcke
Tyrell Software Corp  <http://www.tyrell.com/>



--
Jim Roepcke
Tyrell Software Corp  <http://www.tyrell.com/>



-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.