mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-10 05:51:52 +08:00
Move wsgiref.types to _typeshed.wsgi (#4175)
Re-export the types from wsgiref.types for now to avoid breaking existing code. wsgiref.types should be removed eventually. Also, reduce the boilerplate description in _typeshed/wsgi.pyi as it mirrors the description in _typeshed/__init__.pyi.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
from typing import Any, Iterable, List, Mapping, Optional, Sequence, Set, Text
|
||||
from wsgiref.types import WSGIApplication, WSGIEnvironment, StartResponse
|
||||
from _typeshed.wsgi import WSGIApplication, WSGIEnvironment, StartResponse
|
||||
|
||||
from ..middleware.proxy_fix import ProxyFix as ProxyFix
|
||||
|
||||
|
||||
2
third_party/2and3/werkzeug/exceptions.pyi
vendored
2
third_party/2and3/werkzeug/exceptions.pyi
vendored
@@ -1,7 +1,7 @@
|
||||
import datetime
|
||||
from typing import Any, Dict, Tuple, List, Text, NoReturn, Optional, Protocol, Type, Union, Iterable
|
||||
|
||||
from wsgiref.types import WSGIEnvironment, StartResponse
|
||||
from _typeshed.wsgi import WSGIEnvironment, StartResponse
|
||||
from werkzeug.wrappers import Response
|
||||
|
||||
class _EnvironContainer(Protocol):
|
||||
|
||||
2
third_party/2and3/werkzeug/formparser.pyi
vendored
2
third_party/2and3/werkzeug/formparser.pyi
vendored
@@ -1,5 +1,5 @@
|
||||
from typing import Any, Optional, Text, Tuple, Callable, Iterable, TypeVar, NoReturn, Protocol, IO, Generator, Dict, Mapping, Union
|
||||
from wsgiref.types import WSGIEnvironment
|
||||
from _typeshed.wsgi import WSGIEnvironment
|
||||
|
||||
from .datastructures import Headers
|
||||
|
||||
|
||||
2
third_party/2and3/werkzeug/http.pyi
vendored
2
third_party/2and3/werkzeug/http.pyi
vendored
@@ -4,7 +4,7 @@ from typing import (
|
||||
Dict, Text, Union, Tuple, Any, Optional, Mapping, Iterable, Callable, List, Type,
|
||||
TypeVar, Protocol, overload, SupportsInt,
|
||||
)
|
||||
from wsgiref.types import WSGIEnvironment
|
||||
from _typeshed.wsgi import WSGIEnvironment
|
||||
|
||||
from .datastructures import (
|
||||
Headers, Accept, RequestCacheControl, HeaderSet, Authorization, WWWAuthenticate,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
from typing import Any, Iterable, Mapping, Optional, Text
|
||||
from wsgiref.types import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
from _typeshed.wsgi import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
|
||||
class DispatcherMiddleware(object):
|
||||
app: WSGIApplication
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
from typing import Any, Dict, Iterable, Mapping, MutableMapping, Text
|
||||
from wsgiref.types import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
from _typeshed.wsgi import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
|
||||
_Opts = Mapping[Text, Any]
|
||||
_MutableOpts = MutableMapping[Text, Any]
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import sys
|
||||
from typing import Any, Iterable, Iterator, List, Mapping, Optional, Protocol, Tuple
|
||||
from wsgiref.types import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
from _typeshed.wsgi import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
|
||||
from ..datastructures import Headers
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
from typing import IO, Iterable, List, Optional, Text, Tuple, Union
|
||||
from wsgiref.types import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
from _typeshed.wsgi import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
|
||||
class ProfilerMiddleware(object):
|
||||
def __init__(
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
from typing import Iterable, Optional
|
||||
from wsgiref.types import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
from _typeshed.wsgi import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
|
||||
class ProxyFix(object):
|
||||
app: WSGIApplication
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import datetime
|
||||
from typing import Callable, IO, Iterable, List, Mapping, Optional, Text, Tuple, Union
|
||||
from wsgiref.types import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
from _typeshed.wsgi import StartResponse, WSGIApplication, WSGIEnvironment
|
||||
|
||||
_V = Union[Tuple[Text, Text], Text]
|
||||
|
||||
|
||||
2
third_party/2and3/werkzeug/test.pyi
vendored
2
third_party/2and3/werkzeug/test.pyi
vendored
@@ -1,5 +1,5 @@
|
||||
import sys
|
||||
from wsgiref.types import WSGIEnvironment
|
||||
from _typeshed.wsgi import WSGIEnvironment
|
||||
from typing import Any, Generic, Optional, Text, Tuple, Type, TypeVar, overload
|
||||
from typing_extensions import Literal
|
||||
|
||||
|
||||
2
third_party/2and3/werkzeug/wrappers.pyi
vendored
2
third_party/2and3/werkzeug/wrappers.pyi
vendored
@@ -3,7 +3,7 @@ from datetime import datetime
|
||||
from typing import (
|
||||
Any, Callable, Iterable, Iterator, Mapping, MutableMapping, Optional, Sequence, Text, Tuple, Type, TypeVar, Union, overload
|
||||
)
|
||||
from wsgiref.types import WSGIEnvironment, InputStream
|
||||
from _typeshed.wsgi import WSGIEnvironment, InputStream
|
||||
|
||||
from .datastructures import (
|
||||
Authorization, CombinedMultiDict, EnvironHeaders, Headers, ImmutableMultiDict,
|
||||
|
||||
2
third_party/2and3/werkzeug/wsgi.pyi
vendored
2
third_party/2and3/werkzeug/wsgi.pyi
vendored
@@ -1,5 +1,5 @@
|
||||
from typing import Any, Optional, Protocol, Iterable, Text
|
||||
from wsgiref.types import WSGIEnvironment, InputStream
|
||||
from _typeshed.wsgi import WSGIEnvironment, InputStream
|
||||
|
||||
from .middleware.dispatcher import DispatcherMiddleware as DispatcherMiddleware
|
||||
from .middleware.http_proxy import ProxyMiddleware as ProxyMiddleware
|
||||
|
||||
Reference in New Issue
Block a user