PyO3 / PyO3/pyo3

Supporting in-development Python versions

Open
#5,093 12 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
16.2k
Forks
1k
Avg merge
2d 6h
Merged PRs (30d)
66

Description

This release cycle for Python 3.14 I've seen a lot of user requests for PyO3 to support 3.14 already, and I expect there will be similar demand for 3.15 as soon as 3.14 is stable. Maybe some folks testing 3.15 on CPython main might care as soon as 3.14 is in beta.

At the moment our version check basically refuses to build for 3.14 except in abi3 mode, which is safe but doesn't work for all projects (or free-threaded Python). This is 100% safe but gets in the way of development efforts.

For some reasonable definition of "in-development" Python (TBC how we decide / detect this), I propose that we relax this a bit and just emit warnings (probably at both build time and runtime). Maybe we require opt-in with an environment variable, similar to how we have PYO3_USE_ABI3_FORWARD_COMPATIBILITY for future stable Python versions.

I think also for supporting future versions of CPython, we should allow PRs to support the Python main branch (currently 3.14, soon to be 3.15). We should also run development versions on CI, but they should not block merge until they are stable.

In this direction, I think #4811 should probably also be merged asap as 3.14 beta is very close and we should start testing 3.14 beta in CI.

Would be interested to hear everyone's thoughts on the matter!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the current Python version check and the existing PYO3_USE_ABI3_FORWARD_COMPATIBILITY behavior. Read issue #4811 alongside the proposed CI changes, then determine how in-development CPython versions should be detected, warned about, and gated. Done means a decided policy covering build time, runtime, opt-in behavior, and non-blocking development-version CI.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, rust
Domain
build-system, ci-cd
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.