ci: GitHub Actions test matrix for python 3.10+#30
Merged
Conversation
added 6 commits
May 22, 2026 11:18
Adds keyword-only options to OEClient/AsyncOEClient for use behind corporate proxies and TLS-intercepting setups: - proxy / proxy_auth: route all requests through an HTTP proxy - ssl_context: supply a pre-built ssl.SSLContext - ca_cert: add an extra CA bundle to the default trust store - verify_ssl: disable cert verification (escape hatch) - trust_env: let aiohttp read proxy/.netrc from the environment ClientSession construction is centralised in BaseOEClient._build_session() so proxy and TLS config stay consistent across the sync and async clients and their per-call sessions. Closes #22
py312 made UP046 suggest PEP 695 generics, which break the advertised 3.10/3.11 support (see #28).
Copies .env and .envrc into 'claude --worktree' worktrees so an isolated checkout can run tests and publish without manual setup.
Runs the test suite on python 3.10, 3.11, 3.12 and 3.13, plus a ruff lint/format job. Catches version-support regressions like the PEP 695 syntax break in #28. The two live API tests are skipped unless OPENELECTRICITY_API_KEY is available, so CI is green without a secret; set it as a repo secret to run them too.
enum.StrEnum is 3.11+, so the package failed to import on 3.10 despite advertising requires-python >=3.10. Caught by the new CI matrix. Adds a version-gated shim. Also adds the 3.13 trove classifier now CI covers it.
datetime.UTC is 3.11+, so test_timeseries.py failed to import on 3.10 (caught by the CI matrix). Also applies ruff format to types.py.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds the first CI workflow: a test matrix across python 3.10, 3.11, 3.12 and 3.13, plus a ruff lint/format job.
This is the CI follow-up asked for in #28, where a 3.12-only PEP 695 syntax change silently broke the advertised 3.10/3.11 support with no CI to catch it.
Notes
test_*_get_facilities) are skipped unlessOPENELECTRICITY_API_KEYis set, so CI is green without any secret. Add it as a repo secret to exercise the live path too.feat/proxy-cert-support) so the lint job is green: feat(client): proxy and custom TLS/cert support (#22) #29 sets rufftarget-versionto py310. GitHub will retarget this PR tomainonce feat(client): proxy and custom TLS/cert support (#22) #29 merges. Merge feat(client): proxy and custom TLS/cert support (#22) #29 first.