warn-scraper 1.2.94__py3-none-any.whl → 1.2.95__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
warn/scrapers/va.py CHANGED
@@ -116,19 +116,21 @@ def scrape(
116
116
  chromeoptionsholder.add_argument("--remote-debugging-pipe")
117
117
  chromeoptionsholder.add_argument("--verbose")
118
118
 
119
- chrome_install = ChromeDriverManager().install()
120
-
121
- # Weird error with finding the driver name in Windows. Sometimes.
122
- if chrome_install.endswith("THIRD_PARTY_NOTICES.chromedriver"):
123
- chrome_install = chrome_install.replace(
124
- "THIRD_PARTY_NOTICES.chromedriver", "chromedriver.exe"
125
- )
119
+ if "CHROMEWEBDRIVER" in os.environ:
120
+ chrome_install = os.environ["CHROMEWEBDRIVER"]
121
+ else:
122
+ chrome_install = ChromeDriverManager().install()
123
+
124
+ # Weird error with finding the driver name in Windows. Sometimes.
125
+ if chrome_install.endswith("THIRD_PARTY_NOTICES.chromedriver"):
126
+ chrome_install = chrome_install.replace(
127
+ "THIRD_PARTY_NOTICES.chromedriver", "chromedriver.exe"
128
+ )
126
129
  logger.debug(f"Chrome install variable is {chrome_install}")
127
- # folder = os.path.dirname(chrome_install)
128
- # chromedriver_path = folder # os.path.join(folder, "chromedriver.exe")
129
- # service = ChromeService(chromedriver_path)
130
130
  service = ChromeService(chrome_install)
131
- driver = webdriver.Chrome(options=chromeoptionsholder, service=service)
131
+ driver = webdriver.Chrome(
132
+ options=chromeoptionsholder, service=service, service_args=["--verbose"]
133
+ )
132
134
  logger.debug(f"Attempting to fetch {csv_url}")
133
135
  driver.get(csv_url)
134
136
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: warn-scraper
3
- Version: 1.2.94
3
+ Version: 1.2.95
4
4
  Summary: Command-line interface for downloading WARN Act notices of qualified plant closings and mass layoffs from state government websites
5
5
  Home-page: https://github.com/biglocalnews/warn-scraper
6
6
  Author: Big Local News
@@ -61,13 +61,13 @@ warn/scrapers/sd.py,sha256=_4R19Ybzsyx1PvcWV3_laJmJ3etrwVGfhNEQm6njwoA,1904
61
61
  warn/scrapers/tn.py,sha256=i1H7c09Ea3CDrTXqqRMLBMPT_34QtGA0-x7T8rm_j5Q,2945
62
62
  warn/scrapers/tx.py,sha256=watfR1gyN9w7nluiAOnnIghEmoq3eShNUzYSZ8SkZy4,4438
63
63
  warn/scrapers/ut.py,sha256=iUh38YIjbvv5MyyKacsiZNe8KjfdBeDaOf-qMQEF_kc,2245
64
- warn/scrapers/va.py,sha256=O0TgNW1typgnxbkL9IbXX9WVqUALwMjBnS06t0pnkqM,7805
64
+ warn/scrapers/va.py,sha256=JLrhNHxQ44lCwXJkmSSyQQLucYQ9qs5GU9owwjuDyOg,7803
65
65
  warn/scrapers/vt.py,sha256=d-bo4WK2hkrk4BhCCmLpEovcoZltlvdIUB6O0uaMx5A,1186
66
66
  warn/scrapers/wa.py,sha256=UXdVtHZo_a-XfoiyOooTRfTb9W3PErSZdKca6SRORgs,4282
67
67
  warn/scrapers/wi.py,sha256=ClEzXkwZbop0W4fkQgsb5oHAPUrb4luUPGV-jOKwkcg,4855
68
- warn_scraper-1.2.94.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
69
- warn_scraper-1.2.94.dist-info/METADATA,sha256=VJl78D48qBVeyOuc6aFhtI5lwIpJri1wBaqki4Iqg5A,2118
70
- warn_scraper-1.2.94.dist-info/WHEEL,sha256=Wyh-_nZ0DJYolHNn1_hMa4lM7uDedD_RGVwbmTjyItk,91
71
- warn_scraper-1.2.94.dist-info/entry_points.txt,sha256=poh_oSweObGlBSs1_2qZmnTodlOYD0KfO7-h7W2UQIw,47
72
- warn_scraper-1.2.94.dist-info/top_level.txt,sha256=gOhHgNEkrUvajlzoKkVOo-TlQht9MoXnKOErjzqLGHo,11
73
- warn_scraper-1.2.94.dist-info/RECORD,,
68
+ warn_scraper-1.2.95.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
69
+ warn_scraper-1.2.95.dist-info/METADATA,sha256=LzOK3ChrTaldK164Uxi8tdKnSsUWDAlgl5j0biYvUaY,2118
70
+ warn_scraper-1.2.95.dist-info/WHEEL,sha256=Wyh-_nZ0DJYolHNn1_hMa4lM7uDedD_RGVwbmTjyItk,91
71
+ warn_scraper-1.2.95.dist-info/entry_points.txt,sha256=poh_oSweObGlBSs1_2qZmnTodlOYD0KfO7-h7W2UQIw,47
72
+ warn_scraper-1.2.95.dist-info/top_level.txt,sha256=gOhHgNEkrUvajlzoKkVOo-TlQht9MoXnKOErjzqLGHo,11
73
+ warn_scraper-1.2.95.dist-info/RECORD,,