Skip to content

Commit e73d0c3

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent b9e5287 commit e73d0c3

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

web_programming/covid_stats_via_xpath.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,13 +47,14 @@ def covid_stats(
4747
except httpx.HTTPStatusError as e:
4848
logging.error(f"HTTP error occurred: {e}")
4949
return CovidData("N/A", "N/A", "N/A")
50-
data : list[str] = html.fromstring(response.content).xpath(xpath_str)
50+
data: list[str] = html.fromstring(response.content).xpath(xpath_str)
5151
if len(data) != 3:
5252
logging.warning("Unexpected data format. The page structure may have changed.")
5353
return CovidData("N/A", "N/A", "N/A")
5454

5555
return CovidData(*data)
5656

57+
5758
def main() -> None:
5859
"""CLI entry point."""
5960
parser = argparse.ArgumentParser(

0 commit comments

Comments
 (0)