Skip to content

Conversation

@dylanjmcconnell
Copy link
Member

Closes #30 - drop support / testing of python 3.9, and 3.10 (3.9 EoL, 3.10 EoL this year, and PyPSA 1.0 requires >3.11) and add in 3.13, 3.14. Some third party libraries didn't install with 3.14t (so not supported for now).

  • Added a noxfile.py (for local testing of python versions, before CICD).
  • Updated pyproject.toml
  • Updated cicd.yml*

*Discovered a significant bug in cicd.yml (we weren't actually testing different python versions, just 3.12). Hopefully also fixed / corrected (and turns out we weren't actually supporting 3.9 anyway - (some of our typing syntax requires >3.10)

@codecov
Copy link

codecov bot commented Jan 28, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
see 1 file with indirect coverage changes

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

@dylanjmcconnell
Copy link
Member Author

.. Additionally updated uv.lock file for python version compatibility (I think a --frozen issue)

@nick-gorman
Copy link
Member

Hi Dylan, a few thoughts below:

  • Should we just not test 3.14 as its unstable and could break, also a bit confusing if we are testing for it but not supporting it?? not sure.
  • Should nox be a dev dependency? and should we breifly document how to run the noxfile?
  • is this technically a breaking change requiring a major version bump

Copy link
Member

@nick-gorman nick-gorman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see previous comment

@dylanjmcconnell
Copy link
Member Author

Thanks Nick! Some responses, in order:

  • 3.14 is certainly stable release (released Oct last year). 3.14t (i.e. free-threaded python) is the one I dropped / didn't test (or include in CICD). It is also technically stable, but a handful of libraries currently don't have wheels or don't build. I think we should leave 3.14, but not include 3.14t yet (i.e. essentially as it currently is).
  • No, I don't think nox is a dev dependency (..more of tool, like say git, pip or uv). Not typically installed at project level / not typically a project dependency ( orchestrates environments, it doesn't run inside them - potentially creates some circularity too? As in, nox creates isolated envs, but would need to be installed first to install itself? Not sure - but sort of the same as why you don't have uv,pip,git as a dev dependency) . Will add a note to the contributing.md guidelines (and suggest local version testing is optional - we have not really done this to date mind you).
  • Good point on breaking change. Generally, I think adding new python versions is not breaking, but removing old ones is. In this case, we weren't actually really supporting 3.9 - so that is already broken in a sense (and making 3.,9 work would require code changes, which we shouldn't do). In this case, suggest dropping (only) 3.9, keeping 3.10 for now (and dropping for a bigger / later breaking change).

@nick-gorman
Copy link
Member

Hey Dylan, yep, thanks for clarifying, I'd misunderstood a few things, and it sounds good re-adding 3.10 back in.

@dylanjmcconnell dylanjmcconnell merged commit 8b223a3 into main Jan 29, 2026
18 checks passed
@dylanjmcconnell dylanjmcconnell deleted the upgrade-python branch January 29, 2026 02:11
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.

Update python versions

3 participants