From 4a1e94826b515ed06b8edf372d3b57c68a737cda Mon Sep 17 00:00:00 2001 From: Firepup Sixfifty Date: Tue, 16 Jul 2024 21:09:58 +0000 Subject: [PATCH] Make compatible with python 3.10+, remove `package-mode` key since it is incompatible with older versions of poetry, and it's not a fatal issue in newer ones yet --- logs.py | 6 +++--- pyproject.toml | 3 +-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/logs.py b/logs.py index c5d6f80..6096586 100644 --- a/logs.py +++ b/logs.py @@ -1,5 +1,5 @@ #!/usr/bin/python3 -from datetime import datetime as dt, UTC +from datetime import datetime as dt, timezone as tz from sys import stdout, stderr from typing import Union @@ -15,8 +15,8 @@ def log( else: stream = stdout if time == "now": - dtime = dt.now(UTC) - dtime.replace(tzinfo=UTC) + dtime = dt.now(tz.utc) + dtime.replace(tzinfo=tz.utc) elif type(time) == str: raise ValueError('Only "now" is an accepted string argument for time') elif type(time) == dt: diff --git a/pyproject.toml b/pyproject.toml index 9f4c14d..508b224 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,10 +4,9 @@ version = "0.0.1" description = "A talk/talkd like program" authors = ["Firepup Sixfifty "] readme = "README.md" -package-mode = false [tool.poetry.dependencies] -python = "^3.11" +python = "^3.10" firepup650 = "^1.0.40"