From a46f1d5bf87fe266c59a0146c4148c88eb05661b Mon Sep 17 00:00:00 2001 From: MystyPy Date: Sun, 14 Apr 2024 20:14:30 +1000 Subject: [PATCH] Change list to Sequence --- starlette_plus/core.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/starlette_plus/core.py b/starlette_plus/core.py index 0139896..660d6c5 100644 --- a/starlette_plus/core.py +++ b/starlette_plus/core.py @@ -18,7 +18,7 @@ import asyncio import inspect import logging -from collections.abc import Callable, Coroutine, Iterator +from collections.abc import Callable, Coroutine, Iterator, Sequence from typing import TYPE_CHECKING, Any, Self, TypeAlias, TypedDict, Unpack from starlette.applications import Starlette @@ -49,7 +49,7 @@ class ApplicationOptions(TypedDict, total=False): middleware: list[Middleware] on_startup: list[Callable[[], Coroutine[Any, Any, None]]] on_shutdown: list[Callable[[], Coroutine[Any, Any, None]]] - routes: list[Route | WebSocketRoute | Mount] + routes: Sequence[Route | WebSocketRoute | Mount] __all__ = ("Application", "View", "route", "limit")