diff --git a/requirements.d/development.lock.txt b/requirements.d/development.lock.txt index 131097e7..c58cc41e 100644 --- a/requirements.d/development.lock.txt +++ b/requirements.d/development.lock.txt @@ -10,4 +10,3 @@ pytest-cov==3.0.0 pytest-benchmark==3.4.1 Cython==0.29.30 twine==3.8.0 -python-dateutil==2.8.2 diff --git a/requirements.d/development.txt b/requirements.d/development.txt index 9ecaaafb..8b62f2a0 100644 --- a/requirements.d/development.txt +++ b/requirements.d/development.txt @@ -10,4 +10,3 @@ pytest-cov pytest-benchmark Cython!=0.27 twine -python-dateutil diff --git a/src/borg/testsuite/archiver.py b/src/borg/testsuite/archiver.py index dd8fa48e..272c0410 100644 --- a/src/borg/testsuite/archiver.py +++ b/src/borg/testsuite/archiver.py @@ -1,5 +1,4 @@ import argparse -import dateutil.tz import errno import io import json @@ -2304,8 +2303,8 @@ class ArchiverTestCase(ArchiverTestCaseBase): # Given a date and time in local tz, create a UTC timestamp string suitable # for create --timestamp command line option def _to_utc_timestamp(self, year, month, day, hour, minute, second): - dtime = datetime(year, month, day, hour, minute, second, 0, dateutil.tz.gettz()) - return dtime.astimezone(dateutil.tz.UTC).strftime("%Y-%m-%dT%H:%M:%S") + dtime = datetime(year, month, day, hour, minute, second, 0).astimezone() # local time with local timezone + return dtime.astimezone(timezone.utc).strftime("%Y-%m-%dT%H:%M:%S") def _create_archive_ts(self, name, y, m, d, H=0, M=0, S=0): self.cmd( diff --git a/tox.ini b/tox.ini index 653e160f..861c2432 100644 --- a/tox.ini +++ b/tox.ini @@ -36,5 +36,4 @@ deps = pytest mypy pkgconfig - types-python-dateutil commands = mypy