draft: streaming the audio

This commit is contained in:
2024-05-15 12:18:08 +02:00
parent 14f986a497
commit cc14253239
3 changed files with 47 additions and 22 deletions

View File

@@ -2,7 +2,19 @@ from __future__ import annotations
from collections import defaultdict
from enum import Enum
from typing import List, Dict, Set, Tuple, Optional, Iterable, Generator, TypedDict, Callable, Any
from typing import (
List,
Dict,
Set,
Tuple,
Optional,
Iterable,
Generator,
TypedDict,
Callable,
Any,
TYPE_CHECKING
)
from urllib.parse import urlparse, ParseResult
from dataclasses import dataclass, field
from functools import cached_property
@@ -15,6 +27,8 @@ from ..utils.string_processing import hash_url, shorten_display_url
from .metadata import Mapping, Metadata
from .parents import OuterProxy
from .collection import Collection
if TYPE_CHECKING:
from ..pages.abstract import Page
@@ -78,7 +92,7 @@ class Source:
return self.source_type.page is not None
@property
def page(self) -> OuterProxy:
def page(self) -> Page:
return self.source_type.page
@property