Repository navigation
Require Python 3.12, and bound every dependency floor by what Pyodide ships - #399
Merged
Merged
Conversation
The browser target sets this, in the opposite direction to the obvious one. Pyodide 0.29.5 ships CPython 3.13.2 and its wheels are cp313, so requires-python is a ceiling rather than a floor: 3.14 would make eegprep uninstallable in the browser until Pyodide moves. 3.12 keeps one version of headroom and lets CI cover both 3.12 and the 3.13 the browser actually runs. The matrix drops 3.10 and 3.11 and gains 3.13. tomllib has been in the standard library since 3.11, so the tomli backport and its two try/except shims are dead code and go with it.
Two of these are live bugs rather than tidying. threadpoolctl was declared >=3.6.0 while Pyodide 0.29.5 ships 3.5.0, so the floor is above what the browser can provide and a browser install cannot satisfy it. matplotlib>=3.9.2 would have introduced the same bug, since Pyodide has 3.8.4; 3.8.0 is the newest floor that does not. The rest were fiction in the other direction: numpy>=1.20 ships cp37 through cp39 wheels and cannot install on the Python this package now requires. Floors are now the first release with real 3.12 support, capped by the version Pyodide ships: numpy 2.1.0, scipy 1.14.1, matplotlib 3.8.0, h5py 3.12.1, threadpoolctl 3.5.0. scipy is split by platform. 1.14.1 is exactly what Pyodide has, so the general floor cannot go higher, but scipy built before 1.16.3 fails to dlopen on current macOS with a zero-fill section error, so darwin gets its own floor.
Contributor
There was a problem hiding this comment.
If your organization's extra usage balance is empty, an organization admin can add extra usage credits at claude.ai/admin-settings/usage. If its monthly spend limit was reached, an admin can raise it on the same page. If neither applies, contact Anthropic support.
Once extra usage is available, reopen this pull request to trigger a review.
Contributor
|
Claude encountered an error after 0s —— View job I'll analyze this and get back to you. |
The 3.12 floor landed in the test matrix but not in the jobs that install a single interpreter, so docs, release, ruff/ty, and the Claude workflows all still asked for 3.11 and uv refused: error: The requested interpreter resolved to Python 3.11.16, which is incompatible with the project's Python requirement: `>=3.12` Tested: the failing jobs were "Ruff and ty" and "Build Documentation".
The floor moved but the surrounding claims did not: the README badge, the AGENTS notes, four docs pages, and the six example extensions all still advertised 3.10 or 3.11, and ty was still type-checking against 3.10 semantics. pre-commit.py carried a tomli backport for 3.10 and a matching "tomli is not installed; skipping TOML syntax checks" branch. On a 3.12 floor tomllib is always stdlib, so both are dead, and the branch was a silent skip of a check the script claims to run. Tested: ruff check and format clean, ty clean apart from three pre-existing unresolved torch imports (the local venv has no torch extra), tests/test_extension_catalog.py 22 passed, and ./pre-commit.py --all-files reports OK with config syntax checked.
The 3.13 job failed on the MATLAB engine install, not on eegprep: MATLAB Engine for Python supports Python version 3.9, 3.10, 3.11, and 3.12, but your version of Python is 3.13 uv sync had already succeeded, so every dependency floor resolves on 3.13; only MathWorks' engine has no build for it. The workflow already treats MATLAB as optional and falls through to a plain pytest run when the engine will not start, but the install step aborted the job before reaching that check. Tolerate the install failing so the fall-through runs, which also means this starts working by itself once a MATLAB release covers 3.13, rather than encoding a compatibility table in CI.
development.rst told the reader to build the parity harness venv with --python 3.11 and then pip install -e this working tree into it. Under requires-python >=3.12 that install now fails, so the instruction was not merely stale, it no longer worked. Also split the two-sentence line in faq.rst onto its own lines, per the semantic line break convention.
Removing the tomli backport fixed the TOML half of a false green: a missing parser printed one warning, skipped every file of that type, recorded no error, and let the run print OK. The YAML half was left behind with the identical shape. pyyaml is declared in this script's inline dependencies, so uv installs it before the body runs and the only way to reach the fallback is to start the script without uv. That is a misuse, not a degraded environment, so it now exits with the invocation to use instead of quietly checking nothing. Also corrects the header, which still said config parsing happens "when dependencies are available". It is now unconditional. Tested: ./pre-commit.py --all-files reports OK over 1221 files with config syntax checked.
Pyodide bundles its own build of every compiled package, so a floor above what a Pyodide release ships cannot be satisfied in the browser. That makes these floors and requires-python a ceiling, which is the opposite of how a floor reads and is invisible from the code. The epic branch's tools/check_pyodide_base_resolution.py was supposed to catch this and does not: it matches package names against the Pyodide lock and never compares versions, so threadpoolctl>=3.6.0 sits on that branch today against a distribution shipping 3.5.0, and the gate calls it ok. Filed as #400. These tests close the gap on develop, offline, against the versions Pyodide 0.29.5 bundles. Verified non-vacuous by reintroducing the real bug: threadpoolctl>=3.6.0 fails two of them by name, and a requires-python of >=3.14 fails the interpreter check, since Pyodide runs CPython 3.13.2. Also records the constraint above the floors it governs, which was documented for scipy alone, and bumps the ruff target to py312, missed when the ty target moved. The catalog fixture's python_requires went back to a value no interpreter bump can disturb; pinning it to the project floor coupled an unrelated happy path to every future bump. The field's real behavior, an unsatisfiable floor and a malformed specifier, now has the two tests its eegprep_requires sibling already had and it did not.
This was referenced Sep 21, 2026
This was referenced Sep 21, 2026
neuromechanist
added a commit
to nemarOrg/nemar-cli
that referenced
this pull request
Sep 21, 2026
Two entries, both from sccn/eegprep#399. The Pyodide ceiling: for a browser-bound package, requires-python and every dependency floor cap at what the Pyodide release ships, because micropip has no WebAssembly build to fall back to. This inverts how a floor normally reads and is invisible from the code, which is how threadpoolctl>=3.6.0 reached the epic branch against a distribution shipping 3.5.0. Carries the verified 0.29.5 version table and the warning that the epic branch's own gate compares names, not versions. The MATLAB engine ceiling: each MATLAB release covers a fixed set of Python versions, so adding 3.13 to the matrix went red on MathWorks' engine install while uv sync had already succeeded. The obvious reading is that the new Python broke the package, and that reading is wrong.
neuromechanist
added a commit
that referenced
this pull request
Sep 21, 2026
I claimed threadpoolctl>=3.6.0 was a live browser-install bug against a Pyodide shipping 3.5.0. It is not. threadpoolctl publishes a py3-none-any wheel, so micropip pulls any version straight from PyPI and never touches the bundled build. The floor costs a download, not an install. The constraint is real only where no pure-Python wheel exists, because then Pyodide's build is the only one a browser can have. Checked against PyPI: numpy, scipy, h5py and matplotlib publish none, so their floors genuinely are a ceiling; threadpoolctl does, so its floor is not constrained this way. So the test now enforces the four compiled packages and records threadpoolctl in PYODIDE_PURE_PYTHON, deliberately unenforced, with the reason. Still verified non-vacuous: raising the non-darwin scipy floor to 1.15.0, above the 1.14.1 Pyodide ships, fails three tests by name. The four floors that shipped in #399 were correct and remain unchanged. What was wrong was the stated reason for one of them. Correction also filed on #400, whose original example was the same mistake.
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.
Summary
Pyodide 0.29.5 runs CPython 3.13.2, so the browser is the newest interpreter eegprep has to
satisfy, not the oldest. That inverts the usual reading of these settings:
requires-pythonandthe dependency floors act as a ceiling for the browser target, because Pyodide bundles its own
build of every compiled package and micropip has no WebAssembly fallback when a floor sits above it.
This raises the floor to Python 3.12 and moves every dependency floor up to, but not past, what
Pyodide 0.29.5 ships.
What changed
requires-python = ">=3.12",.python-version3.12, ruff and ty targets 3.12CI matrix
["3.10", "3.11", "3.12"]becomes["3.12", "3.13"], and every single-interpreter jobmoves off 3.11
Dependency floors raised, each at or below the Pyodide 0.29.5 build:
>=2.1.0>=1.14.1>=3.8.0>=3.12.1>=3.5.0macOS takes
scipy>=1.16.3through asys_platformmarker, because scipy built before 1.16.3fails to
dlopenon current macOS. Pyodide reportssys_platform == "emscripten", so thebrowser takes the 1.14.1 branch and the macOS floor never applies there.
The
tomlibackport retires with the 3.10 floor, along with itstry/except tomllibshimsREADME badge,
AGENTS.md, four docs pages and the six example extensions move to 3.12A guard for the constraint, because the existing one does not check versions
epic/324-pyodide-browsercarriestools/check_pyodide_base_resolution.pyfor exactly this, andit does not work: it matches package names against the Pyodide lock and never compares
versions. That branch declares
threadpoolctl>=3.6.0today against a distribution shipping 3.5.0,and running the gate prints
[ok] threadpoolctl==3.6.0: pyodide-lock. Filed as #400.tests/test_browser_dependency_floors.pycloses that ondevelop, offline, against the versionsPyodide 0.29.5 bundles. It was verified non-vacuous by reintroducing the real bug:
>=3.6.0failstwo tests by name, and a
requires-pythonof>=3.14fails the interpreter check.Also in here, from review
supports Python version 3.9, 3.10, 3.11, and 3.12),not on eegprep.
uv syncsucceeded on 3.13. The workflow already treats MATLAB as optional andfalls through to a plain pytest run, but the install aborted the job first; it is now tolerated.
development.rsttold readers to build the parity harness on 3.11 andpip install -ethis treeinto it, which the new floor breaks. That was a broken instruction, not just a stale claim.
pre-commit.pyreported OK while skipping every YAML file when pyyaml was missing, the samefalse green the tomli removal fixed for TOML.
python_requiresin the catalog validator had no test at all, unlike itseegprep_requiressibling; it now has the unsatisfiable-floor and malformed-specifier cases. The happy-path fixture
went back to a value no interpreter bump can disturb.
Verification
torch-extra failurefilterwarnings-as-errors configruff check,ruff format --check,ty checkclean apart from three pre-existing unresolvedtorchimports in an environment without that extra./pre-commit.py --all-filesOK over 1221 filesNotes
develop; Fix the resampling ratio for non-integer sampling rates, and drop sympy #397 removed it. Nothing in this diff changes that.Pyodide interpreter, so a macOS 3.13 job would spend CI on a combination neither the floor nor
the browser target uses.
importlib.abc.Traversableatguifunc/pophelp.py:6is deprecated and removed in 3.14. Not aproblem for this PR; it needs handling before any future 3.14 bump.
Closes nothing on its own; supports #324 and #395.