mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-15 16:27:08 +08:00
* Fix werkzeug environ type PEP 3333 explicitly calls for environ to be a built-in dict. Using a Mapping will not only prevent the dict from being modified (which is explicitly allowed by PEP 3333), it will also cause interaction problems when the environment is passed to other WSGI handlers. Also change the value type from object to Any for convenience. By definition, the values can be anything and can't be type checked. Using object instead of Any forces us to explicitly cast the value whenever we access it. * Use Union[str, unicode] for Werkzeug environment keys This matches the type in wsgiref.types. * Use WSGIEnvironment from wsgiref.types * Add '= ...' to environ attribute