Skip to content

Commit

Permalink
Merge branch 'ut-special'
Browse files Browse the repository at this point in the history
  • Loading branch information
showerst committed Nov 9, 2016
2 parents abdf049 + d8abb9a commit dcdcffb
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
17 changes: 15 additions & 2 deletions openstates/ut/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
'name': '2015-2016',
'start_year': 2015,
'end_year': 2016,
'sessions': ['2015', '2015s1', '2016'],
'sessions': ['2015', '2015s1', '2016', '2016S2', '2016S3'],
},
],
'session_details': {
Expand Down Expand Up @@ -110,7 +110,20 @@
'start_date': datetime.date(2016, 1, 25),
'display_name': '2016 General Session',
'_scraped_name': '2016 General Session',
}
},
#Note: There is no 2016s1, it's 2015s1
'2016S2': {
'type': 'special',
'start_date': datetime.date(2016, 5, 18),
'display_name': '2016 2nd Special Session',
'_scraped_name': '2016 2nd Special Session',
},
'2016S3': {
'type': 'special',
'start_date': datetime.date(2016, 7, 13),
'display_name': '2016 3rd Special Session',
'_scraped_name': '2016 3rd Special Session',
}
},
'feature_flags': ['events', 'subjects', 'influenceexplorer'],
'_ignored_scraped_sessions': [
Expand Down
4 changes: 2 additions & 2 deletions openstates/ut/bills.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ def scrape(self, session, chambers):
if "s" not in session.lower() and "h" not in session.lower():
session_search_text += "GS"


sessions = sessions.xpath(
'//p/a[contains(@href, "{}")]'.format(session_search_text))

session_url = ''

for elem in sessions:
if re.sub(r'\s+', " ", elem.xpath('text()')[0]) == \
self.metadata['session_details'][session]['_scraped_name']:
Expand Down

0 comments on commit dcdcffb

Please sign in to comment.