Skip to content

Drop support for end-of-life Python versions (3.10 first) #491

Closed

Description

@allen0099

Why

Python 3.10 reached end of life in October 2026. We still declare requires-python = ">=3.10", and dependencies are starting to leave 3.10 behind:

Proposed policy

Drop a Python version in the first minor release after its end-of-life date, with a runtime warning in the release line before it (the same rule as any breaking change). State the policy in the docs so future drops (3.11 in October 2027) follow it without a new discussion.

Plan

0.5.x (warn first)

  • On import under Python 3.10, emit a FutureWarning (visible by default, unlike DeprecationWarning) saying 0.6.0 requires Python 3.11+. Add a test, and make sure filterwarnings = ["error"] does not break the 3.10 CI job.
  • Changelog fragment (deprecation).

Done in #493. It ships in the next 0.5.x release, which has to be cut before the first 0.6.0 change below is merged: release.yml releases only from master.

0.6.0 (drop)

  • pyproject.toml: requires-python = ">=3.11", drop the 3.10 classifier, mypy python_version = "3.11", and remove the zensical marker.
  • Remove the import-time warning (_warn_python_310 in fastapi_cachex/__init__.py, its filterwarnings entry in pyproject.toml, and tests/test_python_support.py).
  • CI: drop 3.10 from the test.yml matrix. lowest.yml and tox -e lowest run on 3.11 (tox.ini env_list, base_python, gh-actions map). Recheck the lowest dependency floors on 3.11.
  • Code: let ruff's pyupgrade rules remove 3.10-only shims, such as typing_extensions imports that are stdlib in 3.11 and sys.version_info branches.
  • Docs, in English and zh-TW: MIGRATING_FROM_FASTAPI_CACHE2.md, COMPARISON.md, DEVELOPMENT.md (tox section, Zensical note) and CLAUDE.md.
  • Add docs/MIGRATING_0_6.md with a zh-TW copy and nav entries, containing a "Python 3.11 or later" section. (feat: warn on import under Python 3.10, which 0.6.0 drops #493). In 0.6.0, reword it from "will require" to "requires", but keep the silencing recipes and the #python-311 anchor: the 0.5.x warning links to en/stable/MIGRATING_0_6/#python-311, and once 0.6.0 is out, stable serves the 0.6.0 page to everyone still on 0.5.x and Python 3.10.
  • Write down the support policy above, for example in SECURITY.md or the README.
  • Changelog fragment (removal).

Metadata

Metadata

Assignees

No one assigned

    Labels

    breaking-changeChanges public behaviour or API; needs a minor/major releaseciCI workflows, test suite and tooling

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions