Skip to content

Commit

Permalink
chg: test a typing workaround on python 3.8 !wip
Browse files Browse the repository at this point in the history
Signed-off-by: Stephen Arnold <[email protected]>
  • Loading branch information
sarnold committed Sep 2, 2024
1 parent eb89737 commit cb0c3b9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ setup_requires =

install_requires =
importlib-metadata; python_version < '3.8'
typing-extensions; python_version < '3.10'
munch[yaml]
timew-report
pycairo
Expand Down
6 changes: 5 additions & 1 deletion src/timew_status/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,14 @@
from datetime import timedelta
from pathlib import Path
from shutil import which
from typing import Dict, NewType, Optional

from munch import Munch

if sys.version_info < (3, 10):
from typing_extensions import Dict, NewType, Optional
else:
from typing import Dict, NewType, Optional

TimeDelta = NewType("TimeDelta", datetime.timedelta)
APP_NAME = 'timew_status_indicator'
CFG = {
Expand Down

0 comments on commit cb0c3b9

Please sign in to comment.