diff options
author | Simon Sawicki <contact@grub4k.xyz> | 2023-09-17 12:56:50 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-17 12:56:50 +0200 |
commit | 836e06d246512f286f30c1371b2c54b72c9ecd93 (patch) | |
tree | 1f492da9a5f245b7e96d5a1a45aeb643dd0d1a8d /yt_dlp/extractor/panopto.py | |
parent | 94389b225d9bcf29aa7ba8afaf1bbd7c62204eae (diff) |
[core] Fix support for upcoming Python 3.12 (#8130)
This also adds the following test runners:
- `3.12-dev` on `ubuntu-latest`
- `3.12-dev` on `windows-latest`
- `pypy-3.10` on `ubuntu-latest`
Authored by: Grub4K
Diffstat (limited to 'yt_dlp/extractor/panopto.py')
-rw-r--r-- | yt_dlp/extractor/panopto.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/yt_dlp/extractor/panopto.py b/yt_dlp/extractor/panopto.py index 6e3c9f442..5ab2b2bce 100644 --- a/yt_dlp/extractor/panopto.py +++ b/yt_dlp/extractor/panopto.py @@ -1,7 +1,7 @@ import calendar import json import functools -from datetime import datetime +from datetime import datetime, timezone from random import random from .common import InfoExtractor @@ -243,7 +243,7 @@ class PanoptoIE(PanoptoBaseIE): invocation_id = delivery_info.get('InvocationId') stream_id = traverse_obj(delivery_info, ('Delivery', 'Streams', ..., 'PublicID'), get_all=False, expected_type=str) if invocation_id and stream_id and duration: - timestamp_str = f'/Date({calendar.timegm(datetime.utcnow().timetuple())}000)/' + timestamp_str = f'/Date({calendar.timegm(datetime.now(timezone.utc).timetuple())}000)/' data = { 'streamRequests': [ { |