Skip to content

Drop support for Python 3.9#97

Open
aclerc wants to merge 26 commits into
mainfrom
fix-xio-error
Open

Drop support for Python 3.9#97
aclerc wants to merge 26 commits into
mainfrom
fix-xio-error

Conversation

@aclerc

@aclerc aclerc commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

I saw an error XIO: fatal IO error 0 (Success) on X server "localhost:10.0" when trying to run wind-up on a server overnight. Typical useage of wind-up is fine with Agg as mpl backend so make that happen by default.

During this PR I ran uv lock -U and found the latest matplotlib has dropped support for Python 3.9. 3.9 became EOL in late 2025 so makes sense to drop it now. I looked in to supporting 3.14 but that deserves another PR.

@aclerc aclerc changed the title Fix xio error Drop 3.9 Jun 17, 2026
@aclerc aclerc changed the title Drop 3.9 Drop support for Python 3.9 Jun 17, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR updates wind-up to drop Python 3.9 support (aligning with upstream dependency support) and makes matplotlib default to a headless-safe backend to avoid X-server related failures during unattended runs.

Changes:

  • Drop Python 3.9 support across packaging/tooling and migrate strict_zip backport usage to zip(..., strict=True).
  • Default matplotlib backend to Agg on import wind_up unless MPLBACKEND is explicitly set, and add tests for this behavior.
  • Minor cleanups: plotting arg style tweaks, small typing improvements, and README updates (methodology link + backend note).

Reviewed changes

Copilot reviewed 23 out of 24 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
wind_up/scada_funcs.py Replace strict_zip with built-in zip(..., strict=True) after dropping Py3.9.
wind_up/pp_analysis.py Make bootstrap override handling explicit (is not None).
wind_up/plots/scada_funcs_plots.py Replace strict_zip with zip(..., strict=True).
wind_up/plots/pp_analysis_plots.py Minor matplotlib call style tweak (ylim tuple).
wind_up/plots/northing_plots.py Minor matplotlib call style tweak (xlim tuple).
wind_up/plots/data_coverage_plots.py Minor matplotlib call style tweaks (xlims tuple, ylim tuple).
wind_up/plots/combine_results_plots.py Replace strict_zip with zip(..., strict=True) and enforce strictness.
wind_up/optimize_northing.py Replace strict_zip with zip(..., strict=True).
wind_up/northing.py Use circ_median directly as a groupby aggfunc.
wind_up/models.py Replace strict_zip with zip(..., strict=True) in YAML config construction.
wind_up/backporting.py Remove backport module now that Py3.10+ is required.
wind_up/init.py Set default matplotlib backend to Agg unless MPLBACKEND is set.
tests/test_smart_data.py Update tests to use zip(..., strict=True).
tests/test_rolling_circ_median.py Small refactor: pass function directly into rolling.apply.
tests/test_rolling_circ_mean.py Minor lambda cleanup in expected-series computation.
tests/test_backporting.py Remove tests for backported strict_zip (module removed).
tests/test_backend.py Add regression tests verifying backend defaulting + env override behavior.
tests/pp_analysis/test_cook_pp.py Use zip(..., strict=True) in test data construction.
README.md Document Py3.10–3.13 support, add methodology link + backend note.
pyproject.toml Bump version, require Py3.10+, adjust tooling config and dependency constraints.
examples/smarteole_utils.py Modernize typing to Py3.10 union (`
examples/kelmarsh_kaggle.py Improve typing annotation for automl_settings.
.github/workflows/lint-and-test.yaml Update CI matrix to test Python 3.10 and 3.13.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread wind_up/__init__.py Outdated
aclerc and others added 2 commits June 17, 2026 11:49
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
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