Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop support for Python 3.7, increase minimum versions for SciPy/NumPy #927

Merged
merged 2 commits into from
Nov 18, 2023

Conversation

reneeotten
Copy link
Contributor

Description

Python 3.7 is EOL remove support and testing for it (adding Python 3.12 and switching to GitHub Actions will be in another PR). Additionally, increase minimum supported NumPy and SciPy versions, including a bit of clean-up to code for additional keywords in newer SciPy versions for some minimizers.

I would be happy to push the minimum versions to even more recent ones, but I'll leave that decision to @newville (our "official" policy has been to support version that were released up to ~2 years ago).

Type of Changes
  • Bug fix
  • New feature
  • Refactoring / maintenance
  • Documentation / examples
Tested on

Python: 3.11.6 (main, Oct 3 2023, 00:01:08) [Clang 15.0.0 (clang-1500.0.40.1)]

lmfit: 1.2.2.post13+gac0d35f0, scipy: 1.11.3, numpy: 1.26.1, asteval: 0.9.31, uncertainties: 3.1.7

Verification

Have you

  • included docstrings that follow PEP 257?
  • referenced existing Issue and/or provided relevant link to mailing list?
  • verified that existing tests pass locally?
  • verified that the documentation builds locally?
  • squashed/minimized your commits and written descriptive commit messages?
  • added or updated existing tests to cover the changes?
  • updated the documentation and/or added an entry to the release notes (doc/whatsnew.rst)?
  • added an example?

Copy link

codecov bot commented Nov 18, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (ac0d35f) 93.23% compared to head (9efaa4e) 93.17%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #927      +/-   ##
==========================================
- Coverage   93.23%   93.17%   -0.07%     
==========================================
  Files          10       10              
  Lines        3697     3690       -7     
==========================================
- Hits         3447     3438       -9     
- Misses        250      252       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@newville
Copy link
Member

@reneeotten Great - thanks!

The idea of "2 years back" is from a time when releases of Python were a bit slower, so we could certainly revisit that. Python 3.8 seems very old to me. Yes, it still has 1 more year of support left, but I would be willing to say that we could drop testing with that if it makes life easier. Are all Python packages obligated to test with 5 versions?

If someone did a fresh install of "latest code" 2 years ago, it would likely be Python 3.9, numpy 1.20 or 1.21, and scipy 1.7.0. That seems reasonably recent to me. I don't think we have anything eager to use newer features from any of those.
Do you agree?

So my opinion would be: bump numpy to 1.20 or 1.21, scipy to 1.7.0 or 1.7.1, and keep Python 3.8, but if there is a reason to drop Python 3.8 or increase numpy or scipy to more recent, I am OK with that too.

@newville
Copy link
Member

... and requiring numpy 1.23.0 and scipy 1.8.0 are fine with me!

@reneeotten
Copy link
Contributor Author

I'd prefer keeping Python versions that are still supported - that doesn't take additional work. Going to newer SciPy/Numpy version do allow for some clean-up in the code bur for now going newer than SciPy 1.8 doesn't "help" in that sense - hence the changes in this PR.

@reneeotten reneeotten merged commit e21a6aa into lmfit:master Nov 18, 2023
9 of 13 checks passed
@reneeotten reneeotten deleted the drop-PY37_update-deps branch November 18, 2023 16:46
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