Skip to content

Declare diffrax and orthax as dependencies - #48

Merged
rogeriojorge merged 3 commits into
mainfrom
agent/declare-diffrax-orthax
Oct 24, 2026
Merged

rogeriojorge merged 3 commits into
mainfrom
agent/declare-diffrax-orthax

Conversation

@rogeriojorge

@rogeriojorge rogeriojorge commented Sep 23, 2026 •

Copy link
Copy Markdown
Member

SPECTRAX imports diffrax (time integration) and orthax (inverse Hermite transform), but pyproject.toml did not declare them, so a clean pip install gave a package that fails at import spectrax. requirements.txt already lists both.

Change (pyproject.toml only, 2 lines)

  • Add diffrax and orthax to dependencies.
  • requires-python >=3.5 -> >=3.11. Evidence: diffrax 0.7.2 and matplotlib 3.11 require >=3.11, jax 0.11 requires >=3.12 (pip falls back to jax 0.10.2 on 3.11), tomllib is stdlib from 3.11, and CI tests 3.11 and 3.12. No 3.10 support is claimed or tested.

Evidence (tested SHA 1e795e9, rebased on main ab87385; local)

Fresh venvs, pip install git+file://<clone>@<ref>, then import spectrax and simulation({'t_max': 0.5}, Nx=9, Nn=4, timesteps=3) from outside the source tree:

  • main, Python 3.11.14: ModuleNotFoundError: No module named 'diffrax'.
  • this branch, Python 3.11.14 (jax 0.10.2) and 3.13.9 (jax 0.11.2), diffrax 0.7.2, orthax 0.2.10: imports and runs; identical total_energy[-1] = 1.7500044641735002.
  • python -m pytest -n 2 -q tests (3.12.9, jax 0.11.2): 8 passed.

Overlap: #21 edits the same line (adds solvax); whichever merges second needs a one-line rebase. Side note, not changed here: total_energy is returned with complex dtype (zero imaginary part).

@codecov

codecov Bot commented Sep 23, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

spectrax imports diffrax (time integration) and orthax (inverse Hermite transform), but pyproject.toml did not list them, so pip install left the package unimportable in a clean environment.
diffrax 0.7, matplotlib 3.10+ and current jax need at least 3.11, tomllib is in
the standard library from 3.11, and CI tests 3.11 and 3.12. The old >=3.5
could not resolve.
@rogeriojorge
rogeriojorge merged commit b7505ce into main Oct 24, 2026
3 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.

2 participants