httpbin icon indicating copy to clipboard operation
httpbin copied to clipboard

Fix disabling of location header autocorrect for werkzeug 2+

Open AdamWill opened this issue 3 years ago • 2 comments

In werkzeug 2.0.0 and later, the Location header autocorrection moved from BaseResponse to Response, so we need to set autocorrect_location_header = False in Response not BaseResponse. For now let's just set it in both to be safe, this doesn't cause any errors at least with 1.0.1 and 2.0.1.

Signed-off-by: Adam Williamson [email protected]

AdamWill avatar Jul 19 '21 22:07 AdamWill

Fixes #647

AdamWill avatar Jul 19 '21 22:07 AdamWill

@kinlane This PR is a pre-requisite for getting the tests running again when we move them to GitHub Actions - see https://github.com/MikeRalphson/httpbin/actions/runs/1174257560

MikeRalphson avatar Aug 27 '21 12:08 MikeRalphson

Closing in favor of #674 , as setting both isn't valid any more (plus this wasn't doing it entirely right).

AdamWill avatar Sep 14 '22 23:09 AdamWill