Re-declare scipy as a direct dependency - #1148
Merged
Merged
Conversation
scipy is imported directly by shipped source in hssm.plotting (gaussian_kde, chi2) but reaches installs only transitively via pymc after #1137 dropped the explicit entry. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Contributor
|
Caution Review failedAn error occurred during the review process. Please try again later. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
scipy>=1.10to[project.dependencies], dropped in Fixed numpy version #1137.src/hssm/plotting/predictive.py:13—from scipy.stats import gaussian_kdesrc/hssm/plotting/quantile_probability.py:14—from scipy.stats import chi2hssm.plottingbreaks at import with no constraint to protect it — the same undeclared-direct-import fragility behind the numpy 2.5row_stackCI breakage (drift: numpy 2.5 broke the fast suite on fresh resolves (row_stack removed) #1144).Why this is not the #1145 objection
#1145 was rightly closed for declaring versions of transitive dependencies, which transfers version-management burden to us for packages we never import. That objection does not apply here: scipy is imported directly by code we ship, so declaring it is standard packaging practice (PEP 508 — declare what you import). The floor is deliberately loose (
>=1.10, resolving to 1.18.0 today) so it constrains nothing in practice; it only guarantees scipy is present.Verification
uv lock— no lockfile change; scipy already resolved at a satisfying version.uv run prek run --all-files— ruff check/format and all file hooks pass. The mypy and pyrefly hooks fail identically on unmodifiedmain(14 pre-existing errors intests/rl/test_rlssm.pyandtests/addm/oracle/validation.py); unrelated to this change.from scipy.stats import gaussian_kde, chi2and bothhssm.plottingmodules import cleanly (scipy 1.18.0).🤖 Generated with Claude Code