diff --git a/juriscraper/opinions/united_states/state/ky.py b/juriscraper/opinions/united_states/state/ky.py index 81f43ad89..5eafee67f 100644 --- a/juriscraper/opinions/united_states/state/ky.py +++ b/juriscraper/opinions/united_states/state/ky.py @@ -29,7 +29,7 @@ class Site(OpinionSiteLinear): # Home: https://appellatepublic.kycourts.net/login first_opinion_date = datetime(1982, 2, 18).date() - days_interval = 10 # page size of 25 + days_interval = 7 # page size of 25 api_court = "Kentucky Supreme Court" api_url = ( @@ -62,7 +62,7 @@ def set_url( """ if not start: end = datetime.now() - start = end - timedelta(30) + start = end - timedelta(7) logger.info("Date range %s %s", start, end) params = { @@ -73,8 +73,8 @@ def set_url( "searchFields[1].operation": "<=", "searchFields[1].values[0]": end.strftime("%m/%d/%Y"), "searchFields[1].indexFieldName": "filedDate", - "searchFilters[0].indexFieldName": "caseHeader.court", "searchFilters[0].operation": "=", + "searchFilters[0].indexFieldName": "caseHeader.court", "searchFilters[0].values[0]": self.api_court, } self.url = f"{self.api_url}{urlencode(params)}" @@ -119,6 +119,12 @@ def _process_html(self) -> None: # May contain the case name disposition = re.split(self.judge_regex, disposition)[0] + if disposition.upper() in [ + "OPINION OF THE COURT", + "OPINION AND ORDER", + ]: + disposition = "" + if self.test_mode_enabled(): # detail request has been manually nested in the test file doc_json = result["detailJson"]