collective / funnelweb

Easy static site imports for CMS
14 stars 3 forks source link

Failures when trying to generate illegal content give uninformative error messages #4

Open auspex opened 14 years ago

auspex commented 14 years ago

I don't know what this one was, but a similar error was generated when I tried to create Document objects inside the Plone "news" folder - which obviously needs "News Item" objects. I suspect that here it is trying to create a Folder - but we can't tell from the message. Please dump the type and source URL before aborting.

  File "bin/funnelweb", line 115, in <module>
    funnelweb.runner.runner({'ploneupload': {'target': 'http://admin:0oFz2RwZ@localhost:12000/otn/news'}, 'template1': {'text': 'html //div[@id="dal_content"]/div[@class="content"]', 'image': 'html //div[@id="dal_content"]/div[@class="content"]/table//img', 'image-caption': 'html //div[@id="dal_content"]/div[@class="content"]/table//font', 'title': 'html //div[@id="dal_content"]/div[@class="content"]/h3'}, 'titleguess': {'condition': 'python:True'}, 'changetype': {'value': "python:{'Document':'News Item'}.get(item['_type'],item['_type'])"}, 'crawler': {'url': 'http://oceantrackingnetwork.org/news'}})
  File "/home/derek/aptana/buildout-cache/eggs/funnelweb-1.0b3-py2.6.egg/funnelweb/runner/__init__.py", line 55, in runner
    transmogrifier(u'transmogrify.config.funnelweb', **overrides)
  File "/home/derek/aptana/buildout-cache/eggs/collective.transmogrifier-1.2-py2.6.egg/collective/transmogrifier/transmogrifier.py", line 62, in __call__
    for item in pipeline:
  File "/home/derek/aptana/buildout-cache/eggs/transmogrify.webcrawler-1.0b3-py2.6.egg/transmogrify/webcrawler/staticcreator.py", line 34, in __iter__
    for item in self.previous:
  File "/home/derek/aptana/buildout-cache/eggs/transmogrify.ploneremote-1.0b1-py2.6.egg/transmogrify/ploneremote/remoteprune.py", line 88, in __iter__
    for item in self.previous:            
  File "/home/derek/aptana/buildout-cache/eggs/transmogrify.ploneremote-1.0b1-py2.6.egg/transmogrify/ploneremote/remoteredirector.py", line 27, in __iter__
    for item in self.previous:
  File "/home/derek/aptana/buildout-cache/eggs/transmogrify.ploneremote-1.0b1-py2.6.egg/transmogrify/ploneremote/remoteworkflowupdater.py", line 41, in __iter__
    for item in self.previous:
  File "/home/derek/aptana/buildout-cache/eggs/collective.transmogrifier-1.2-py2.6.egg/collective/transmogrifier/sections/inserter.py", line 19, in __iter__
    for item in self.previous:
  File "/home/derek/aptana/buildout-cache/eggs/transmogrify.ploneremote-1.0b1-py2.6.egg/transmogrify/ploneremote/remotenavigationexcluder.py", line 34, in __iter__
    for item in self.previous:
  File "/home/derek/aptana/buildout-cache/eggs/transmogrify.ploneremote-1.0b1-py2.6.egg/transmogrify/ploneremote/remoteschemaupdater.py", line 33, in __iter__
    for item in self.previous:
  File "/home/derek/aptana/buildout-cache/eggs/transmogrify.ploneremote-1.0b1-py2.6.egg/transmogrify/ploneremote/remoteconstructor.py", line 74, in __iter__
    pproxy.invokeFactory(type_, id)
  File "/usr/lib/python2.6/xmlrpclib.py", line 1199, in __call__
    return self.__send(self.__name, args)
  File "/usr/lib/python2.6/xmlrpclib.py", line 1489, in __request
    verbose=self.__verbose
  File "/usr/lib/python2.6/xmlrpclib.py", line 1243, in request
    headers
xmlrpclib.ProtocolError: <ProtocolError for admin:***@localhost:12000/otn/news/: 401 Unauthorized>
djay commented 13 years ago

yes you are right. I will put in some logging for this.

FvD commented 11 years ago

Illegal content can also be a file name that does not comply to Plone standards (for instance a { bracket in an image name). The traceback is similar:

Traceback (most recent call last): File "./bin/funnelweb", line 116, in mr.migrator.runner.runner({},"funnelweb.remote") File "/home/frans/Development/PloneDevelopment/SSP_4.2/buildout-cache/eggs/mr.migrator-1.0.1-py2.6.egg/mr/migrator/runner/init.py", line 132, in runner transmogrifier(pipelineid, overrides) File "/home/frans/Development/PloneDevelopment/SSP_4.2/buildout-cache/eggs/collective.transmogrifier-1.5-py2.6.egg/collective/transmogrifier/transmogrifier.py", line 63, in call for item in pipeline: File "/home/frans/Development/PloneDevelopment/SSP_4.2/buildout-cache/eggs/transmogrify.ploneremote-1.3-py2.6.egg/transmogrify/ploneremote/remoteprune.py", line 147, in iter remote_ids = self.getRemoteObjectIds(item) File "/home/frans/Development/PloneDevelopment/SSP_4.2/buildout-cache/eggs/transmogrify.ploneremote-1.3-py2.6.egg/transmogrify/ploneremote/remoteprune.py", line 57, in getRemoteObjectIds contents = proxy.listFolderContents() File "/home/frans/Development/PloneDevelopment/SSP_4.2/Python-2.6/lib/python2.6/xmlrpclib.py", line 1199, in call return self.send(self.name, args) File "/home/frans/Development/PloneDevelopment/SSP_4.2/Python-2.6/lib/python2.6/xmlrpclib.py", line 1489, in request verbose=self.verbose File "/home/frans/Development/PloneDevelopment/SSP_4.2/Python-2.6/lib/python2.6/xmlrpclib.py", line 1253, in request return self._parse_response(h.getfile(), sock) File "/home/frans/Development/PloneDevelopment/SSP_4.2/Python-2.6/lib/python2.6/xmlrpclib.py", line 1392, in _parse_response return u.close() File "/home/frans/Development/PloneDevelopment/SSP_4.2/Python-2.6/lib/python2.6/xmlrpclib.py", line 838, in close raise Fault(self._stack[0]) xmlrpclib.Fault: <Fault -1: "Unexpected Zope exception: <class 'zExceptions.NotFound'> -

This is causes the same kind of confusion, as sphinx-doc is a more forgiving when it comes to naming referenced files (images for instance)