You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
logger.warning(f"Failure in URL request or reading the response after {attempt} tries for station {station_id} param {param}. Link=\n{link_url}\nException below:")
169
+
logger.warning(
170
+
f"Failure in URL request or reading the response after {attempt} tries for station {station_id} param {param}. Link=\n{link_url}\nException below:"
171
+
)
169
172
logger.exception(e)
170
173
failures.append((station_id, agency_id, var, param))
171
174
attampt=0
172
175
return
173
-
else:
174
-
time.sleep(attempt) # Wait one second more second each time to clear any short term bad stuff
176
+
else:
177
+
time.sleep(
178
+
attempt
179
+
) # Wait one second more second each time to clear any short term bad stuff
175
180
iflen(station_html) >30andnot"No sites found matching"instation_html:
176
181
found=True
177
-
ifattempt>1: logger.info(f"{station_id} found on attempt {attempt}")
182
+
ifattempt>1:
183
+
logger.info(f"{station_id} found on attempt {attempt}")
178
184
withopen(fpath, "w") asf:
179
185
f.write(station_html)
180
186
else:
181
187
logger.info(f"{station_id} not found after attempt {attempt}")
182
188
logger.info("Station %s produced no data"%station)
183
189
failures.append((station_id, agency_id, var, param))
0 commit comments