New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix urllib3 mocking to conform to current API #602
base: master
Are you sure you want to change the base?
Conversation
New rev with fixes for 3.5 and 3.6 - turns out the old behaviour of the mock was what they wanted. Proof tox is passing for these versions: https://github.com/Perfect5th/talisker/actions/runs/5438859830/jobs/9890351211 Will work on other failing CI bits soon (docs, etc) |
Bumping the Sphinx version gets the docs building again (see https://github.com/Perfect5th/talisker/actions/runs/5439103405), so this now also closes #599 and therefore closes #600 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, LGTM now.
Looks like this was left behind, sorry for missing it. diff --git a/requirements.tests.txt b/requirements.tests.txt
index d36d68c..2765aa8 100644
--- a/requirements.tests.txt
+++ b/requirements.tests.txt
@@ -16,7 +16,7 @@ setuptools==44.0.0;python_version<"3.10"
setuptools>64;python_version>="3.10"
coverage==5.0.3;python_version<"3.10"
coverage>=6;python_version>="3.10"
-flaky==3.6.1
+flaky==3.8.1
# for integration tests
# eventlet is pinned until https://github.com/benoitc/gunicorn/pull/2581 If you want to include the change in your PR, it should land (tested locally) |
I've added the suggested flaky dependency version change to the PR, thanks @verterok ! |
The expected responses from
requests
requests are now instances ofurllib3.response.HTTPResponse
, nothttp.client.HTTPResponse
. This change both fixes that, and ensures the response can be read by fixing the incorrect HTTP message (it was missing a CRLF). I also added aContent-Type
header because sometimes the request body does not get read if this header is absent.tox should pass for
py38
andpy310
. I didn't testpy35
andpy36
as both are now EOL.fixes #601