1

After moving my buildout from one server to another, along with the Data.fs and blobstorage directory I'm starting to get the following error when I visit the site front page:

Error Type: AttributeError
Error Value: __getitem__

Here's the traceback:

2013-07-23 19:55:20 ERROR Zope.SiteErrorLog 1374602120.540.80110008228 http://myplonesite.org:19086/Plone    
  Module ZPublisher.Publish, line 115, in publish                                                               
  Module ZPublisher.BaseRequest, line 437, in traverse                                                          
  Module Products.CMFCore.PortalObject, line 78, in __before_publishing_traverse__                              
  Module zope.event, line 23, in notify                                                                         
  Module zope.component._api, line 136, in subscribers                                                          
  Module zope.component.registry, line 321, in subscribers                                                      
  Module zope.component.event, line 32, in objectEventNotify                                                    
  Module zope.component._api, line 136, in subscribers                                                          
  Module zope.interface.adapter, line 583, in subscribers                                                       
  Module plone.app.theming.plugins.hooks, line 37, in onRequest                                                 
AttributeError: __getitem__                                                                                     
2013-07-23 19:55:20 ERROR plone.subrequest Error handling subrequest to /++theme++ccrp-5.9/rules.xml            
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/plone.subrequest-1.6.7-py2.7.egg/plone/subrequest/__init_
_.py", line 116, in subrequest                                                                                  
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/Zope2-2.13.8-py2.7.egg/ZPublisher/BaseRequest.py", line 4
37, in traverse                                                                                                 
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/Zope2-2.13.8-py2.7.egg/ZPublisher/BeforeTraverse.py", lin
e 97, in __call__                                                                                               
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/Products.CMFCore-2.2.4-py2.7.egg/Products/CMFCore/PortalO
bject.py", line 78, in __before_publishing_traverse__                                                           
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/zope.event-3.5.0_1-py2.7.egg/zope/event/__init__.py", lin
e 23, in notify                                                                                                 
    subscriber(event)                                                                                           
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/zope.component-3.9.5-py2.7.egg/zope/component/event.py", 
line 24, in dispatch                                                                                            
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/zope.component-3.9.5-py2.7.egg/zope/component/_api.py", l
ine 136, in subscribers                                                                                         
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/zope.component-3.9.5-py2.7.egg/zope/component/registry.py
", line 321, in subscribers                                                                                     
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/zope.interface-3.6.3-py2.7-linux-x86_64.egg/zope/interfac
    subscription(*objects)                                                                                      
line 32, in objectEventNotify                                                                                   
    zope.component.subscribers((event.object, event), None)                                                     
ine 136, in subscribers                                                                                         
    return sitemanager.subscribers(objects, interface)                                                          
", line 321, in subscribers                                                                                     
    return self.adapters.subscribers(objects, provided)                                                         
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/zope.interface-3.6.3-py2.7-linux-x86_64.egg/zope/interfac
e/adapter.py", line 583, in subscribers                                                                         
    subscription(*objects)                                                                                      
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/plone.app.theming-1.1-py2.7.egg/plone/app/theming/plugins
/hooks.py", line 37, in onRequest                                                                               
    themeDirectory = queryResourceDirectory(THEME_RESOURCE_NAME, theme)                                         
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/plone.resource-1.0.2-py2.7.egg/plone/resource/utils.py", 
line 62, in queryResourceDirectory                                                                              
AttributeError: __getitem__                                                                                     
2013-07-23 19:55:20 ERROR plone.transformchain Unexpected error whilst trying to apply transform chain          
Traceback (most recent call last):                                                                              
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/plone.transformchain-1.0-py2.7.egg/plone/transformchain/t
ransformer.py", line 42, in __call__                                                                            
    newResult = handler.transformIterable(result, encoding)                                                     
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/plone.app.theming-1.1-py2.7.egg/plone/app/theming/transfo
rm.py", line 170, in transformIterable                                                                          
    transform = self.setupTransform(runtrace=runtrace)                                                          
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/plone.app.theming-1.1-py2.7.egg/plone/app/theming/transfo
rm.py", line 108, in setupTransform                                                                             
    transform = compileThemeTransform(rules, absolutePrefix, readNetwork, parameterExpressions, runtrace=runtrac
e)                                                                                                              
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/plone.app.theming-1.1-py2.7.egg/plone/app/theming/utils.p
y", line 579, in compileThemeTransform                                                                          
    runtrace=runtrace,                                                                                          
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/diazo-1.0.3-py2.7.egg/diazo/compiler.py", line 107, in co
mpile_theme                                                                                                     
    read_network=read_network,                                                                                  
  File "/home/plone/ccrp.transmorgrifier.buildout/eggs/diazo-1.0.3-py2.7.egg/diazo/rules.py", line 166, in proce
ss_rules                                                                                                        
    rules_doc = etree.parse(rules, parser=rules_parser)                                                         
  File "lxml.etree.pyx", line 2706, in lxml.etree.parse (src/lxml/lxml.etree.c:49958)                           
  File "parser.pxi", line 1500, in lxml.etree._parseDocument (src/lxml/lxml.etree.c:71797)                      
  File "parser.pxi", line 1529, in lxml.etree._parseDocumentFromURL (src/lxml/lxml.etree.c:72080)               
  File "parser.pxi", line 1429, in lxml.etree._parseDocFromFile (src/lxml/lxml.etree.c:71175)                   
  File "parser.pxi", line 975, in lxml.etree._BaseParser._parseDocFromFile (src/lxml/lxml.etree.c:68173)        
  File "parser.pxi", line 539, in lxml.etree._ParserContext._handleParseResultDoc (src/lxml/lxml.etree.c:64257) 
  File "parser.pxi", line 625, in lxml.etree._handleParseResult (src/lxml/lxml.etree.c:65178)                   
  File "parser.pxi", line 563, in lxml.etree._raiseParseError (src/lxml/lxml.etree.c:64493)                     
IOError: Error reading file '/++theme++ccrp-5.9/rules.xml': failed to load external entity "/++theme++ccrp-5.9/r
ules.xml"                                                   
David Bain
  • 2,439
  • 1
  • 17
  • 19
  • Looking at this answer: http://stackoverflow.com/questions/7570183/unable-to-use-diazo-plone-app-theming-on-centos I wondered if it may be due to my build of lxml which I copied from another folder. So I deleted the lxml egg from my eggs folder and re-ran buildout so that it would build a fresh lxml. Unfortunately the error persists after this. – David Bain Jul 23 '13 at 18:05
  • It seems the rules.xml file is missing. – Lennart Regebro Jul 25 '13 at 16:08
  • It it is indeed a missing rules.xml file, then I need a way to deactivate the theme. I also need to find out why it might have gone missing in the first place. – David Bain Jul 25 '13 at 18:01
  • Try to go to `/@@theming-controlpanel`, you should be able to disable theming there. – Lennart Regebro Jul 25 '13 at 18:29
  • I should have mentioned that this error shows up just about everywhere, including the ZMI and when I visit @@theming-controlpanel. – David Bain Jul 25 '13 at 21:21
  • Then the easiest way forward is definitely to find the rules.xml file, or make a new one. That control panel should be unthemed, so the rules.xml file should not need to actually work. – Lennart Regebro Jul 26 '13 at 04:13

1 Answers1

0

In moving the site I did not relocate the blobstorage files properly on the new server. After putting blobstorage and filestorage in the right place, everything just worked as expected. These errors were caused by missing blobstorage items.

David Bain
  • 2,439
  • 1
  • 17
  • 19