-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
FIX: fix reading from http/https urls via imread #18185
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
Conversation
55ba612
to
980c649
Compare
Fixed and squashed. |
closes matplotlib#18129 Co-authored-by: Tim Hoffmann <2836374+timhoffm@users.noreply.github.com>
980c649
to
5d5d919
Compare
fix and squashed again. |
|
||
|
||
@pytest.mark.network | ||
@pytest.mark.flaky |
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.
We could run python -m http.server
in the background to get an always-available server that doesn't need access to the external network, but not sure it's worth the added complexity.
Travis macOS doesn't like the certificates; is it not set up properly? |
Tried restarting just to be sure, but it looks like this is failing with https certificat failures on osx 🤦 |
Now it is failing to find the host at all... |
The version of macOS that we use to test on Travis was changed to 10.12 recently so that we test on older systems too. It could be that Travis hasn't applied all OS updates? |
That sounds like an intermittent network failure. But I can reproduce the certificate problem in a separate repository: https://travis-ci.com/github/jkseppan/bookish-octo-winner/builds/178843673 |
And the fix is to use |
certifi was already an indirect dependency but make it explicit
Here's my suggestion as a PR to your branch: tacaswell#23 |
Try put |
Very much from the peanut gallery: perhaps |
Very much from the peanut gallery: perhaps `subprocess.run([sys.executable, "-mhttp.server"])` in a separate thread is simpler after all?
It's probably simpler, but actually connecting to an https url in this test revealed a real problem with older systems, not just something that happened to be wrong with the Travis environment. I don't know if it's better to run the script from the Python installer package or to use certifi at run time, but we depend on certifi already via some other package.
|
Fix ssl fetching on older systems
…185-on-v3.3.x Backport PR #18185 on branch v3.3.x (FIX: fix reading from http/https urls via imread)
PR Summary
Uses the suggested fix of @tdpetrou .
closes #18129
PR Checklist