Skip to content

Commit

Permalink
FL: tighten senate bill xpath, and improve error messaging. (#4717)
Browse files Browse the repository at this point in the history
  • Loading branch information
showerst authored Nov 9, 2023
1 parent 45b219b commit c3a59d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scrapers/fl/bills.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ def process_page(self):


class BillList(HtmlListPage):
selector = XPath("//a[contains(@href, '/Session/Bill/')]")
selector = XPath("//th/a[contains(@href, '/Session/Bill/')]")
next_page_selector = XPath("//a[@class='next']/@href")
dependencies = {"subjects": SubjectPDF}

Expand Down Expand Up @@ -99,7 +99,7 @@ def process_item(self, item):
elif bill_id.startswith(("SM ", "HM ")):
bill_type = "memorial"
else:
raise ValueError("Failed to identify bill type.")
raise ValueError(f"Failed to identify bill type for {bill_id}")

bill = Bill(
bill_id,
Expand Down

0 comments on commit c3a59d7

Please sign in to comment.