Skip to content

Commit

Permalink
KY: Expanded skipping for actions that could not be parsed.
Browse files Browse the repository at this point in the history
  • Loading branch information
Andy Lo committed Apr 11, 2016
1 parent 0ec5854 commit ae4d876
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion openstates/ky/bills.py
Expand Up @@ -171,6 +171,8 @@ def parse_bill(self, chamber, session, bill_id, url):
# Separate out the date if first action on the line.
if index == 0:
action = '-'.join(action.split('-')[1:]).strip()
if not action:
continue

if action.endswith('House') or action.endswith('(H)'):
actor = 'lower'
Expand Down Expand Up @@ -214,7 +216,7 @@ def parse_bill(self, chamber, session, bill_id, url):
# Capitalize the first letter of the action for nicer
# display. capitalize() won't work for this because it
# lowercases all other letters.
action = action[0].upper() + action[1:]
action = (action[0].upper() + action[1:]).strip()

bill.add_action(actor, action, action_date, type=atype)

Expand Down

0 comments on commit ae4d876

Please sign in to comment.