Python: Concurrency Bugs and Free-Threading Cleanup

This cycle's core theme is reliability under concurrency: fixes to ProcessPoolExecutor, readline, BytesIO, and string.Template close race conditions exposed by free-threaded builds and long-running processes, alongside a cluster of backports and CI infrastructure updates.

Duration: PT2M54S

Episode overview

This episode is a short developer briefing from Python.

It explains recent repository work in plain language.

  • Show: Python
  • Published: 2026-07-09T13:08:22Z
  • Audio duration: PT2M54S

Transcript excerpt

This excerpt keeps the crawler page concise. Listen to the episode or use the RSS feed for the full update.

Good day, and welcome to Python for July ninth, twenty twenty-six.

The clearest signal this cycle is concurrency correctness. Multiple merged fixes target race conditions that only surface under load or in free-threaded builds.

The biggest of these is PR 152978 from Gregory P. Smith, fixing ProcessPoolExecutor so it no longer strands submitted work when a worker hits its max tasks per child limit and exits. The bug could hang interpreter exit or even crash the manager thread once the executor was garbage collected. It's already been…

Readline shows up twice this cycle. Beyond that race fix, PR 153184 stops readline from silently overriding the LINES and COLUMNS environment variables at import time, a behavior that broke terminal resize handling for any process launched afterward.

The second theme is configuration and runtime correctness. Victor Stinner's PR 153301 makes PyConfig_Set actually update the matching global flag, so setting inspect through the C API now reflects properly in sys dot flags. Companion work in PR 153352 adds full test coverage for PyRun functions, catching that…

Elsewhere, a long-standing urllib bug fix, PR 146506, corrects header priority in do_open so…

Nearby episodes from Python

  1. Free-Threading Race Conditions Take Center Stage
  2. Correctness Fixes and a New Tkinter Accessibility Push
  3. The IMAP Library Gets a Deep Cleanup
  4. Weekly Recap - IMAP Overhaul & Parser Hardening
  5. Old Bugs, Long Overdue Fixes
  6. Free-Threading Races and a Reliability Sweep
  7. Concurrency Bugs Get Squashed Across Branches
  8. Security Fixes and Code Cleanup