Skip to content

Commit

Permalink
Update to current werkzeug API (see postmanlabs#673)
Browse files Browse the repository at this point in the history
  • Loading branch information
wosc committed Oct 4, 2023
1 parent 7297004 commit 5b97351
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 3 additions & 4 deletions httpbin/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,9 @@
abort,
)
from six.moves import range as xrange
from werkzeug.datastructures import WWWAuthenticate, MultiDict
from werkzeug.datastructures import Authorization, WWWAuthenticate, MultiDict
from werkzeug.http import http_date
from werkzeug.wrappers import BaseResponse
from werkzeug.http import parse_authorization_header
from werkzeug.wrappers import Response as BaseResponse
from flasgger import Swagger, NO_SANITIZER

from . import filters
Expand Down Expand Up @@ -1158,7 +1157,7 @@ def digest_auth(
authorization = request.headers.get("Authorization")
credentials = None
if authorization:
credentials = parse_authorization_header(authorization)
credentials = Authorization.from_header(authorization)

if (
not authorization
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,6 @@
include_package_data = True, # include files listed in MANIFEST.in
install_requires=[
'Flask', 'MarkupSafe', 'decorator', 'itsdangerous', 'six', 'brotlipy',
'raven[flask]', 'werkzeug>=0.14.1', 'gevent', 'flasgger'
'raven[flask]', 'werkzeug>=2.1', 'gevent', 'flasgger'
],
)

0 comments on commit 5b97351

Please sign in to comment.