💾 Archived View for tris.fyi › pydoc › amethyst.config captured on 2022-03-01 at 16:05:17. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2022-01-08)
-=-=-=-=-=-=-
This module has no docstring.
Config(hosts: List[amethyst.config.HostConfig], handler: Callable[[str, amethyst.request.Connection], Awaitable[amethyst.response.Response]], port: int = 1965)
from_config(cfg)
load(self, cfg)
port = 1965
HostConfig(host: str, tls: amethyst.config.TLSConfig, path_map: Dict[str, Callable[[amethyst.request.Context], Awaitable[amethyst.response.Response]]])
from_config(cfg)
TLSConfig(host: str, auto: bool = False, cert_path: Optional[str] = None, key_path: Optional[str] = None, _context_cache: Optional[Tuple[datetime.datetime, ssl.SSLContext]] = None)
clear_context_cache(self)
from_config(host, cfg)
get_ssl_context(self)
auto = False
cert_path = None
key_path = None
dataclass(cls=None, /, *, init=True, repr=True, eq=True, order=False, unsafe_hash=False, frozen=False) Returns the same class as was passed in, with dunder methods added based on the fields defined in the class. Examines PEP 526 __annotations__ to determine fields. If init is true, an __init__() method is added to the class. If repr is true, a __repr__() method is added. If order is true, rich comparison dunder methods are added. If unsafe_hash is true, a __hash__() method function is added. If frozen is true, fields may not be assigned to after instance creation.
Dict = typing.Dict A generic version of dict.
Handler = typing.Callable[[str, amethyst.request.Connection], typing.Awaitable[amethyst.response.Response]]
List = typing.List A generic version of list.
Optional = typing.Optional Optional type. Optional[X] is equivalent to Union[X, None].
Resource = typing.Callable[[amethyst.request.Context], typing.Awaitable[amethyst.response.Response]]
Tuple = typing.Tuple Tuple type; Tuple[X, Y] is the cross-product type of X and Y. Example: Tuple[T1, T2] is a tuple of two elements corresponding to type variables T1 and T2. Tuple[int, float, str] is a tuple of an int, a float and a string. To specify a variable-length tuple of homogeneous type, use Tuple[T, ...].
registry = {'filesystem': <class 'amethyst.resource.FilesystemResource'>, 'pydoc': <class 'amethyst_ext.pydoc.PydocResource'>, 'redirect': <class 'amethyst_ext.redirect.RedirectResource'>}