Deprecation Warnings With Python 3.12
Describe the bug When the 2.5.0~rc1 test suite is run with python3.12, there are deprecation warnings:
tests/test_resolver.py::PollResolverTestCase::testQuicNameserver
/usr/lib/python3/dist-packages/aioquic/tls.py:218: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC).
now = utcnow()
tests/test_resolver.py::PollResolverTestCase::testQuicNameserver
/usr/lib/python3/dist-packages/aioquic/tls.py:1390: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC).
timestamp = utcnow()
To Reproduce Run the test suite with Python 3.12
Context (please complete the following information):
- dnspython version [e.g. 2.2.1] 2.5.0~rc1
- Python version [e.g. 3.10.0] 3.12.1
- OS: [e.g. macOS Monterey] Debian Unstable
This is an aioquic issue which will be fixed in a future release of aioquic, probably shortly after cryptography 42.0.0 ships.
See this aioquic PR for the latest info.
Excellent. Thanks.
Scott K
I'll keep this ticket open so we remember to increment the aioquic version requirement when there is a fix.
Fixed with aioquic 1.0.0 requirement.