collective / iwwb.eventlist

iwwb.eventlist
http://pypi.python.org/pypi/iwwb.eventlist
0 stars 0 forks source link

A wrong date in in the source can cause the whole search to fail #13

Open pysailor opened 11 years ago

pysailor commented 11 years ago

Currently there's an event in the IWWB source with a bogus StartDate, 2013-26-11T00:00:00, instead of 2013-11-26T00:00:00

This causes the complete search to fail = no results are displayed.

The error occurs somewhere in suds, as the following traceback shows.

2013-02-15 18:06:51 ERROR iwwb.eventlist Can't parse IWWB search results.
Traceback (most recent call last):
  File "/home/zope/gfb.buildout/eggs/iwwb.eventlist-0.2.1-py2.6.egg/iwwb/eventlist/searcher.py", line 69, in get_results
    **query
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/client.py", line 542, in __call__
    return client.invoke(args, kwargs)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/client.py", line 602, in invoke
    result = self.send(soapenv)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/client.py", line 643, in send
    result = self.succeeded(binding, reply.message)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/client.py", line 678, in succeeded
    reply, result = binding.get_reply(self.method, reply)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/bindings/binding.py", line 165, in get_reply
    result = unmarshaller.process(nodes[0], resolved)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/typed.py", line 66, in process
    return Core.process(self, content)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/core.py", line 48, in process
    return self.append(content)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/core.py", line 63, in append
    self.append_children(content)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/core.py", line 140, in append_children
    cval = self.append(cont)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/core.py", line 63, in append
    self.append_children(content)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/core.py", line 140, in append_children
    cval = self.append(cont)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/core.py", line 63, in append
    self.append_children(content)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/core.py", line 140, in append_children
    cval = self.append(cont)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/core.py", line 64, in append
    self.append_text(content)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/typed.py", line 133, in append_text
    content.text = self.translated(content.text, known)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/umx/typed.py", line 139, in translated
    return resolved.translate(value)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/xsd/sxbuiltin.py", line 177, in translate
    return DateTime(value).datetime
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/sax/date.py", line 293, in __init__
    Date.__init__(self, part[0])
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/sax/date.py", line 53, in __init__
    self.date = self.__parse(date)
  File "/home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/sax/date.py", line 104, in __parse
    raise ValueError, 'Invalid format "%s"' % s
ValueError: Invalid format "2013-26-11"
> /home/zope/gfb.buildout/eggs/suds-0.4-py2.6.egg/suds/sax/date.py(104)__parse()
-> raise ValueError, 'Invalid format "%s"' % s
pysailor commented 11 years ago

I added a ticket for this in the suds tracker: https://fedorahosted.org/suds/ticket/456