Skip to content

test: fetch iread() URL-handling test image from GitHub, not petercorke.com - #56

Merged
petercorke merged 1 commit into
mainfrom
test/iread-url-use-github-cdn
Aug 3, 2026
Merged

test: fetch iread() URL-handling test image from GitHub, not petercorke.com#56
petercorke merged 1 commit into
mainfrom
test/iread-url-use-github-cdn

Conversation

@petercorke

Copy link
Copy Markdown
Owner

Summary

  • `test_iread` and `test_iread_url_handling` (`tests/base/test_io.py`) both fetch `https://petercorke.com/files/images/monalisa.png\` over real HTTPS to exercise `iread()`'s URL-fetch path. This has been a repeated source of flaky CI failures this cycle -- PR fix: add socket timeout to iread() URL fetches #37 added a socket timeout so a slow/unavailable server fails fast instead of hanging, but that doesn't remove the dependency on that one personal server's uptime.
  • Switched both to `raw.githubusercontent.com`, serving the identical image already tracked in this repo (`packages/mvtb-data/mvtbdata/images/monalisa.png` -- confirmed same `(700, 677, 3)` shape as the file the old URL served, so the existing assertions are unchanged). GitHub's raw content is CDN-backed, considerably more robust under CI load (many parallel matrix legs) than a single personal server, and since the file already lives in this repo there's no new dependency to maintain -- it's a staple MVTB test image that isn't going anywhere.

Test plan

  • Both tests run and pass against the real new URL (not mocked)

…ke.com

test_iread and test_iread_url_handling both hit
https://petercorke.com/files/images/monalisa.png over real HTTPS to
exercise iread()'s URL-fetch path. PR #37 (6ff62b1) fixed the
repeated flaky failures these caused by adding a socket timeout, but
that only makes a slow/unavailable personal server fail fast instead
of hanging -- it doesn't remove the dependency on that server's
uptime.

Switched both to raw.githubusercontent.com, serving the identical
image already tracked in this repo
(packages/mvtb-data/mvtbdata/images/monalisa.png -- confirmed same
(700, 677, 3) shape as the file the old URL served). GitHub's raw
content is served via a CDN, considerably more robust under CI load
than a single personal server, and since the file already lives in
this repo there's no new dependency to maintain.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 0 complexity · 0 duplication

Metric Results
Complexity 0
Duplication 0

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@petercorke
petercorke merged commit 2c238a7 into main Aug 3, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant