Permalink
Browse files

Cope with double closing bracket.

There's a double closing bracket on one of the notes.
  • Loading branch information...
Duncan Parkes
Duncan Parkes committed Mar 29, 2016
1 parent 514efb2 commit 92bb4aa61ef28835f6489bb5e248bf9f21adf3de
Showing with 1 addition and 1 deletion.
  1. +1 −1 scraper.py
View
@@ -72,7 +72,7 @@ def handle_chamber(chamber_name, source_url, data, term_data):
member['area'] = ''
name_link = tr.cssselect('.jsn-table-column-name')[0].find('a')
name, note = re.match(r'\s+([^\(]+)\s*(?:\((.+)\))?', name_link.text).groups()
name, note = re.match(r'\s+([^\(]+)\s*(?:\((.+)\)+)?', name_link.text).groups()
member['name'] = name.strip()
if note:
member['note'] = note

0 comments on commit 92bb4aa

Please sign in to comment.