Repository: openstates/openstates-scrapers

Issue:
FL failing since at least 2019-06-06
FL has been failing since 2019-06-06

Based on automated runs it appears that FL has not run successfully in 7 days (2019-06-06).


```
  04:15:55 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/138/BillText/Filed/HTML
04:15:56 WARNING pupa: No analysis table for SB 138
04:15:56 WARNING pupa: No vote table for SB 138
04:15:56 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/bills.aspx?Chamber=B&SessionId=87&BillNumber=138
04:15:57 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/billsdetail.aspx?BillId=62960
04:15:58 INFO pupa: save bill SB 138 in 2019 as bill_c551d672-8cc8-11e9-a3ce-027a69baf1c2.json
04:15:58 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/139/ByCategory
04:15:59 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/139/BillText/Filed/PDF
04:16:00 WARNING pupa: No analysis table for HB 139
04:16:00 WARNING pupa: No vote table for HB 139
04:16:00 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/bills.aspx?Chamber=B&SessionId=87&BillNumber=139
04:16:01 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/billsdetail.aspx?BillId=63019
04:16:02 INFO pupa: save bill HB 139 in 2019 as bill_c7adc64c-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:02 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/140/ByCategory
04:16:04 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/140/BillText/Filed/HTML
04:16:04 WARNING pupa: No analysis table for SB 140
04:16:04 WARNING pupa: No vote table for SB 140
04:16:04 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/bills.aspx?Chamber=B&SessionId=87&BillNumber=140
04:16:05 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/billsdetail.aspx?BillId=62961
04:16:06 INFO pupa: save bill SB 140 in 2019 as bill_ca180f6e-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:06 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/141/ByCategory
04:16:08 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/141/BillText/Filed/PDF
04:16:09 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/141/BillText/c1/PDF
04:16:10 WARNING pupa: No vote table for HB 141
04:16:10 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/bills.aspx?Chamber=B&SessionId=87&BillNumber=141
04:16:11 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/billsdetail.aspx?BillId=63020
04:16:12 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Committees/billvote.aspx?VoteId=49824&IsPCB=0&BillId=63020&
04:16:13 INFO pupa: save vote_event 2019 - 2019-03-12T13:30:00-04:00 - Favorable With Committee Substitute (Agriculture & Natural Resources Subcommittee) as vote_event_d07c3f24-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:13 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Committees/billvote.aspx?VoteId=50768&IsPCB=0&BillId=63020&
04:16:14 INFO pupa: save vote_event 2019 - 2019-03-26T08:30:00-04:00 - Favorable (Agriculture & Natural Resources Appropriations Subcommittee) as vote_event_d11c7a84-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:14 INFO pupa: save bill HB 141 in 2019 as bill_ccc774d4-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:14 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/142/ByCategory
04:16:15 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/142/BillText/Filed/HTML
04:16:16 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/142/BillText/c1/HTML
04:16:17 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/142/BillText/e1/HTML
04:16:18 WARNING pupa: No version table for SB 142
04:16:18 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/142/Vote/2019-02-05 0200PM~S00142 Vote Record.PDF
04:16:19 INFO pupa: save vote_event 2019 - 2019-02-05T02:00:00-05:00 - Favorable as vote_event_d4643b0a-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:19 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/142/Vote/2019-03-06 1030AM~S00142 Vote Record.PDF
04:16:20 INFO pupa: save vote_event 2019 - 2019-03-06T10:30:00-05:00 - Favorable with Committee Substitute as vote_event_d5071d7a-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:20 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/142/Vote/2019-03-13 1000AM~S00142 Vote Record.PDF
04:16:21 INFO pupa: save vote_event 2019 - 2019-03-13T10:00:00-04:00 - Favorable as vote_event_d58c68c2-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:21 WARNING pupa: No vote table for SB 142
04:16:21 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/bills.aspx?Chamber=B&SessionId=87&BillNumber=142
04:16:22 INFO scrapelib: GET - http://www.myfloridahouse.gov/Sections/Bills/billsdetail.aspx?BillId=62967
04:16:23 INFO pupa: save bill SB 142 in 2019 as bill_d11dd668-8cc8-11e9-a3ce-027a69baf1c2.json
04:16:23 INFO scrapelib: GET - http://flsenate.gov/Session/Bill/2019/143/ByCategory
04:16:24 WARNING scrapelib: sleeping for 10 seconds before retry
04:16:35 WARNING scrapelib: sleeping for 20 seconds before retry
04:16:55 WARNING scrapelib: sleeping for 40 seconds before retry
```

Visit http://bobsled.openstates.org for more info.



Discussion:

Resolving patch:
diff --git a/openstates/fl/bills.py b/openstates/fl/bills.py
--- a/openstates/fl/bills.py
+++ b/openstates/fl/bills.py
@@ -73,11 +73,12 @@ def handle_list_item(self, item):
 class BillDetail(Page):
 
     def handle_page(self):
-        self.process_history()
-        self.process_versions()
-        self.process_analysis()
-        yield from self.process_votes()
-        yield from self.scrape_page_items(HousePage, bill=self.obj)
+        if self.doc.xpath("//div[@id = 'tabBodyBillHistory']//table"):
+            self.process_history()
+            self.process_versions()
+            self.process_analysis()
+            yield from self.process_votes()
+            yield from self.scrape_page_items(HousePage, bill=self.obj)
 
     def process_versions(self):
         try:
@@ -515,6 +516,11 @@ def handle_page(self):
 class FlBillScraper(Scraper, Spatula):
 
     def scrape(self, session=None):
+        # FL published a bad bill in 2019, #143
+        self.raise_errors = False
+        self.retry_attempts = 1
+        self.retry_wait_seconds = 3
+
         if not session:
             session = self.latest_session()
             self.info('no session specified, using %s', session)


Test patch: