[exchange] XE format change, broke currency list

Bug #825217 reported by Stefano Rivera
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ibid
Fix Committed
Medium
Stefano Rivera

Bug Description

15:41 <tumbleweed> exchange 1 USD for ZAR
15:41 <tibid> I'm not feeling too well

ERROR core.dispatcher: Exception occured in Currency processor of conversions plugin.
Event: {'account': 1, 'responses': [], 'source': u'atrum', 'addressed': True, 'processed': False, 'time': datetime.datetime(2011, 8, 12, 13, 40, 36, 196314), 'identity': 1, 'message': {'raw': u'exchange 1 USD for ZAR', 'deaddressed': u'exchange 1 USD for ZAR', 'clean': u'exchange 1 USD for ZAR', 'stripped': u'exchange 1 USD for ZAR'}, 'type': u'message', 'public': False, 'channel': u'tumbleweed!<email address hidden>', 'sender': {'nick': u'tumbleweed', 'connection': u'tumbleweed!<email address hidden>', 'id': u'tumbleweed'}}
Traceback (most recent call last):
  File "/home/stefanor/bzr/ibid/stefanor/tibid/ibid/core.py", line 29, in process
    processor.process(event)
  File "/home/stefanor/bzr/ibid/stefanor/tibid/ibid/plugins/__init__.py", line 165, in process
    method(event, *args)
  File "/home/stefanor/bzr/ibid/stefanor/tibid/ibid/plugins/conversions.py", line 383, in exchange
    self._load_currencies()
  File "/home/stefanor/bzr/ibid/stefanor/tibid/ibid/plugins/conversions.py", line 321, in _load_currencies
    tbl_main = [x for x in etree.getiterator('table') if x.get('class') == 'tbl_main'][0]
IndexError: list index out of range

$ curl 'http://www.xe.com/iso4217.php'
<HTML>
<HEAD><TITLE>Autoextraction Prohibited</TITLE></HEAD>
<BODY>
Automated extraction of our content is prohibited. See <A HREF="http://www.xe.com/errors/noautoextract.htm">http://www.xe.com/errors/noautoextract.htm</A>.
</BODY>
</HTML>

Related branches

Revision history for this message
Stefano Rivera (stefanor) wrote :

Oh, whoops, with the user-agent we use, I don't get autoextraction prohibited. It could just be a layout change

Changed in ibid:
assignee: nobody → Stefano Rivera (stefanor)
status: New → In Progress
summary: - [exchange] XE won't let us scrape their ISO4217 list
+ [exchange] XE format change, broke currency list
Changed in ibid:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.