Page MenuHomePhabricator

Add support for Python 3.13
Closed, ResolvedPublicFeature

Description

Feature summary (what you would like to be able to do and where):

I would like to request the addition of support for Python 3.13 on the platform, which currently supports up to Python 3.11. This enhancement would allow developers to utilize the latest features and optimizations available in Python 3.13, improving application performance and development efficiency.

Use case(s) (list the steps that you performed to discover that problem, and describe the actual underlying problem which you want to solve. Do not describe only a solution):

  1. I began developing a new project that requires the latest features and performance enhancements available in Python.
  2. Upon reviewing the platform’s supported Python versions, I noticed that it only supports up to Python 3.11.
  3. I researched the features introduced in Python 3.13, including improvements in error handling, performance enhancements, and new libraries that could significantly benefit my project.
  4. The limitation of not being able to use Python 3.13 means missing out on these advancements, which could lead to less efficient code and longer development times.

The underlying problem is that as a developer, I cannot leverage the improvements and new capabilities of Python 3.13 due to its absence on the platform, which hinders my ability to build modern, efficient applications.

Benefits (why should this be implemented?):

  • Enhanced Concurrency: Python 3.13 introduces significant improvements in concurrency handling, allowing developers to write more efficient asynchronous code. This is crucial for applications that require high levels of parallelism, such as web servers and data processing pipelines.
  • Increased Speed: With optimizations in the core interpreter and standard library, applications running on Python 3.13 can achieve substantial speed improvements—often between 10-60% faster than previous versions. This boost in speed is essential for performance-critical applications where response time is vital.
  • Access to New Features: The introduction of new libraries and language features in Python 3.13 can enhance functionality and simplify coding tasks, allowing developers to write cleaner and more efficient code.
  • Staying Current: Supporting the latest version of Python ensures that developers can keep their applications up-to-date with industry standards, reducing technical debt and improving maintainability.

Event Timeline

LLM-generated task descriptions aren't useful.

In particular, what is "the platform"? Pywikibot? That detail is conspicuously missing here.

Please do not use LLMs to create any tasks here. Thanks a lot.

LucasWerkmeister subscribed.

“Classic” webservice images – the python3.9, python3.11, etc. types – are backed by Debian, so historically they’ve become available with each new Debian release. The release of Debian 12 (Bookworm) in June 2023 made Python 3.11 available; assuming nothing unusual happens to the Debian and Python release schedules, we can expect Debian 13 (Trixie) to release with Python 3.13 next summer, at which point it would be possible to create a python3.13 webservice type. (Last time, the task for this process was only filed a few months before the expected release: see T335507.)

It should also be possible to use the Toolforge Build Service to build custom images using Python 3.13, though I couldn’t get it to work right now (our Heroku / Pack / Something™ version might be outdated? – edit: see T381923).

(Tool-python-toolforge is for the toolforge Python library, not for general Python issues on Toolforge, hence untagging. And I agree that there’s a lot of unnecessary fluff in the task description. The value of using recent software versions is well understood and does not need to be inflated using vague truisms like “introduction of new libraries and language features”.)

In particular, what is "the platform"?

I mean Toolforge PAAS here

Please do not use LLMs to create any tasks here. Thanks a lot.

New here. Thank you very much, noted.

Note if you must use Python 3.13, you can create a Bookworm Kubernetes shell using toolforge webservice python3.11 shell (note you can no longer use Bastion for this since decommision of Grid Engine), and manually compile Python 3.13 there from source code. Several years ago I did this for 3.7 before it is available (T230961).

The compiled Python installation will be usable in any Bookworm-based shell, and may no longer work if Bookworm is phased out - but it is at least three years from now.

dcaro triaged this task as Medium priority.Jan 7 2025, 1:55 PM
dcaro moved this task from Backlog to Ready to be worked on on the Toolforge board.
taavi changed the task status from Open to Stalled.Jul 23 2025, 12:32 PM
taavi changed the status of subtask T400255: Build Trixie based Toolforge pre-built images from Open to Stalled.
taavi subscribed.

It should also be possible to use the Toolforge Build Service to build custom images using Python 3.13, though I couldn’t get it to work right now (our Heroku / Pack / Something™ version might be outdated? – edit: see T381923).

Just gonna mention here that Python 3.13 is already available and works just fine in the Toolforge Build Service now (using --use-latest-versions) – I’ve been migrating several of my tools to Python 3.13 over the past weeks already. (See the SAL of quickcategories, wd-image-positions, lexeme-forms, etc. for details if you’re interested.)

taavi changed the task status from Stalled to Open.Aug 12 2025, 3:52 PM
taavi claimed this task.