This code is going to be used to scrape the UCPD Daily Incident page at a pre-determined frequency and store the incidents on a generic JSON data-store.
(ucpd-incident-scraper-py3.11) michaelp@MacBook-Air-18 ucpd-incident-scraper % make three_days
python -m incident_scraper days-back 3
Beginning the UCPD Incident scraping process.
Finished with the UCPD Incident scraping process.
23 total incidents were scraped from the UCPD Incidents' site.
API queries_quota: 60
This incident contains voided information: {'Incident': 'Void', 'Location': 'Void', 'Reported': 'Void', 'Occurred': 'Void', 'Comments / Nature of Fire': 'Number generated in error', 'Disposition': 'Void'}
1 of 23 contained malformed or voided information.
0 of 23 could not be processed by the Census or GoogleMaps' Geocoder.
22 of 23 incidents were successfully processed.
Adding 22 of 23 incidents to the GCP Datastore.
Completed adding 22 of 23 incidents to the GCP Datastore.
1 of 23 incidents could NOT be added to the GCP Datastore.
Program shutting down, attempting to send 1 queued log entries to Cloud Logging...
Waiting up to 5 seconds.
Sent all pending logs.
(ucpd-incident-scraper-py3.11) michaelp@MacBook-Air-18 ucpd-incident-scraper %
Describe your changes
Updated packages.
Checklist before requesting a review