|
3 | 3 | # license that can be found in the LICENSE file. |
4 | 4 | import decimal |
5 | 5 | import os |
6 | | -from typing import TypeVar |
| 6 | +from typing import List, TypeVar |
7 | 7 |
|
8 | 8 | from m3u8.mixins import BasePathMixin, GroupedBasePathMixin |
9 | 9 | from m3u8.parser import format_date_time, parse |
@@ -453,7 +453,7 @@ def _create_sub_directories(self, filename): |
453 | 453 | T = TypeVar("T") |
454 | 454 |
|
455 | 455 |
|
456 | | -class TagList(list[T]): |
| 456 | +class TagList(List[T]): |
457 | 457 | def __str__(self): |
458 | 458 | output = [str(tag) for tag in self] |
459 | 459 | return "\n".join(output) |
@@ -716,7 +716,7 @@ def base_uri(self, newbase_uri): |
716 | 716 | self.init_section.base_uri = newbase_uri |
717 | 717 |
|
718 | 718 |
|
719 | | -class SegmentList(list[Segment], GroupedBasePathMixin): |
| 719 | +class SegmentList(List[Segment], GroupedBasePathMixin): |
720 | 720 | def dumps(self, timespec="milliseconds", infspec="auto"): |
721 | 721 | output = [] |
722 | 722 | last_segment = None |
@@ -831,7 +831,7 @@ def __str__(self): |
831 | 831 | return self.dumps(None) |
832 | 832 |
|
833 | 833 |
|
834 | | -class PartialSegmentList(list[PartialSegment], GroupedBasePathMixin): |
| 834 | +class PartialSegmentList(List[PartialSegment], GroupedBasePathMixin): |
835 | 835 | def __str__(self): |
836 | 836 | output = [str(part) for part in self] |
837 | 837 | return "\n".join(output) |
@@ -1314,7 +1314,7 @@ def __str__(self): |
1314 | 1314 | return self.dumps() |
1315 | 1315 |
|
1316 | 1316 |
|
1317 | | -class RenditionReportList(list[RenditionReport], GroupedBasePathMixin): |
| 1317 | +class RenditionReportList(List[RenditionReport], GroupedBasePathMixin): |
1318 | 1318 | def __str__(self): |
1319 | 1319 | output = [str(report) for report in self] |
1320 | 1320 | return "\n".join(output) |
|
0 commit comments