Repository navigation
chore!: drop Python 3.10 support - #4105
Merged
Merged
Conversation
haystack-ai main (3.5.0rc0) and the upcoming 3.4.0 require Python >=3.11, so the nightly "run unit tests with Haystack main branch" step fails on every 3.10 leg. Move the minimum tested version to 3.11 in all workflows and the workflow template. llama_stack's push default and coverage gates use 3.12, its minimum version. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
… tests numpy 1.22 has no cp311 wheels, so the lowest-direct job on Python 3.11 built it from source and faiss-cpu 1.8.0 failed to import with "module compiled against API version 0x10 but this version of numpy is 0xf". numpy 1.23.2 is the first release with cp311 wheels. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Python 3.10 reaches end of life in October 2026, and haystack-ai 3.4.0 requires Python >=3.11. Set requires-python to >=3.11 and remove the 3.10 classifier in every integration and in the pyproject template. - Ruff now targets 3.11, so `hatch run fmt` applied its autofixes: `datetime.UTC` instead of `timezone.utc`, `Self`/`NotRequired` from `typing`, and `TimeoutError` instead of `asyncio.TimeoutError`. - Public `(str, Enum)` classes keep their base and get `# noqa: UP042`: `StrEnum` would change their `str()` output. - Remove backports that only applied to 3.10: mcp's `exceptiongroup` dependency, cognee's litellm cap and sqlalchemy's pandas 2 marker. - Remove stale ruff `target-version` settings, so ruff infers the target from `requires-python`. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Contributor
Contributor
Coverage report (huggingface_api)Click to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||||||||||||||
Contributor
Coverage report (anthropic)Click to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Contributor
Coverage report (docling)Click to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||
Contributor
Coverage report (transformers)Click to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||
Contributor
Contributor
Contributor
Coverage report (llama_cpp)Click to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||
Contributor
Contributor
Contributor
Contributor
Member
Author
|
@sjrl Regarding the six failures: hetzner is fixed on main now. The other five are quota/API key issues. Not related to this PR. |
sjrl
approved these changes
Oct 16, 2026
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.
Related Issues
Proposed Changes:
Python 3.10 reaches end of life in October 2026. This PR drops it from all integrations, as the
chore!:PRs in January 2026 did for 3.9:requires-python = ">=3.11", and thePython :: 3.10classifier is removed. This applies to the 104 integrations that still allowed 3.10 and toscripts/utils/templates/pyproject.toml.ruff check --fixandruff formatin every integration (the same ashatch run fmt). The fixes it made:datetime.UTCinstead oftimezone.utc(UP017)SelfandNotRequiredfromtypinginstead oftyping_extensions(UP035)TimeoutErrorinstead ofasyncio.TimeoutError(UP041)timezoneimport is removed by hand, sinceF401is unfixable in their config.(str, Enum)classes keep their base, marked# noqa: UP042:ExportTypein docling and docling_serve,ConversionModein docling_serve,Commandin github,TruncationDirectionin huggingface_api,RankerTruncateModein nvidia.StrEnum,str()and f-strings would render the value instead ofExportType.MARKDOWN. That user-visible change doesn't belong in this PR. haystack keptChatRolethe same way.exceptiongroupbackport dependency and its imports. The builtinExceptionGroupis the same class on 3.11+.litellm<1.97.0; python_version < '3.11'cap and its comment.python_version < '3.11'. It is now justpandas>=3.0.0.target-versionsettings removed (py310in deepeval, mcp, valkey and watsonx;py39in llama_stack). Ruff now infers the target fromrequires-python.How did you test it?
ruff checkandruff format --checkpass in all 107 integrations.Locally on Python 3.11,
hatch run test:typesandhatch run test:unitpass for 16 of the 20 integrations whose source changed, plus cognee and sqlalchemy for their dependency changes:docling, transformers, llama_cpp and vllm (torch, llama.cpp or vLLM builds) are covered by this PR's CI only.
Notes for the reviewer
!makes git-cliff mark this commit as breaking in every integration's changelog. As with the 3.9 drop, each integration's next release should be a major version.Checklist
fix:,feat:,build:,chore:,ci:,docs:,style:,refactor:,perf:,test:.🤖 Generated with Claude Code