Repository navigation
Commit ab8dbfc
chore(deps): take numpy 2.4 and record the ceiling's real reason
The `numpy>=2,<2.4` ceiling arrived on 2026-07-23 (71c41c3) explained as
"NumPy 2.4+ bundles PEP 695 syntax in its stubs; mypy targeting the
supported Python 3.11 floor cannot parse those stubs." Dependabot has been
proposing the widening since 2026-08-23; the PR could not merge because
Dependabot edits pyproject.toml without regenerating uv.lock, so the
lock-check gate fails (CONTRIBUTING.md documents the manual step).
Bringing the lock along was the moment to check the reason, and it does
not hold for the released 2.4 line:
numpy 2.4.0 and 2.4.6 wheels each ship 264 .pyi files, and none of them
contains a PEP 695 `type` statement or a PEP 695 generic parameter list.
The mypy half is true and worth keeping in view -- mypy 2.2.0 at
--python-version 3.11 still rejects `type Alias = int` with "Type
statement is only supported in Python 3.12 and greater [syntax]" -- so the
comment now says that a stub release using one turns lint red, rather than
naming a version that never did.
What does hold is a harder constraint the old comment did not mention:
numpy 2.5.0 requires Python >=3.12, and 3.11 is a supported floor here
(pyproject `environments` pins the resolution to 3.11-3.13). `<2.5` is
therefore what keeps the lock resolvable, not a preference.
uv.lock moves numpy 2.3.5 -> 2.4.6 rather than only widening the range: a
ceiling raised without moving the pin claims compatibility that nothing
tests. requirements-docker.lock is unchanged -- numpy is in `dev`, which
the cloud/postgres export does not include, and `src/` imports numpy
nowhere.
Verified locally with numpy 2.4.6 installed: `mypy src/
--ignore-missing-imports` (the exact lint-job command) reports "Success:
no issues found in 157 source files", `uv lock --check` passes (256
packages), `uv export` leaves requirements-docker.lock untouched, and
tests/unit/test_windows_shard_thread_pinning.py -- the only test that
imports numpy -- passes (8 passed).
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018ybRVCaL1Lyd9d5kFTndh31 parent fb2deb2 commit ab8dbfc
2 files changed
Lines changed: 86 additions & 81 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
96 | | - | |
97 | | - | |
98 | | - | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
99 | 106 | | |
100 | 107 | | |
101 | 108 | | |
| |||
0 commit comments