Skip to content

Commit

Permalink
chore(code): proper type hint
Browse files Browse the repository at this point in the history
  • Loading branch information
dhruvinsh committed Nov 6, 2023
1 parent 2288f54 commit 5e83da6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# https://www.python-httpx.org/advanced/#timeout-configuration
_REQUEST_TIMEOUT: int = int(os.getenv("REQUEST_TIMEOUT", "5"))
# timeouts are disabled if None is used
REQUEST_TIMEOUT: int = None if _REQUEST_TIMEOUT == -1 else _REQUEST_TIMEOUT
REQUEST_TIMEOUT: int | None = None if _REQUEST_TIMEOUT == -1 else _REQUEST_TIMEOUT

BASE_PATH: Path = Path(".")

Expand Down
4 changes: 3 additions & 1 deletion src/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,9 @@ def main() -> None:
schedule.run_all()

if not config.ONESHOT:
logger.info(f"Schedule is setup to run every {config.DAYS} day at {config.TIME}")
logger.info(
f"Schedule is setup to run every {config.DAYS} day at {config.TIME}"
)
while True:
schedule.run_pending()
time.sleep(1)

0 comments on commit 5e83da6

Please sign in to comment.