diff --git a/tornado/routing.py b/tornado/routing.py index ee81f9770..ef99c20b2 100644 --- a/tornado/routing.py +++ b/tornado/routing.py @@ -184,7 +184,7 @@ def request_callable(request): from tornado.log import app_log from tornado.util import basestring_type, import_object, re_unescape, unicode_type -from typing import Any, Union, Optional, Awaitable, List, Dict, Pattern, Tuple, overload +from typing import Any, Union, Optional, Awaitable, List, Dict, Pattern, Tuple, overload, Sequence class Router(httputil.HTTPServerConnectionDelegate): @@ -286,7 +286,7 @@ def finish(self) -> None: # _RuleList can either contain pre-constructed Rules or a sequence of # arguments to be passed to the Rule constructor. -_RuleList = List[ +_RuleList = Sequence[ Union[ "Rule", List[Any], # Can't do detailed typechecking of lists.