PyCoder’s Weekly: Issue #762: Refactoring With AI, Binary Search, Race Conditions, and More (2026-11-24)

Wait 5 sec.

#762 – NOVEMBER 24, 2026 View in Browser » How to Refactor Python Code With an AI Agent Learn how to refactor Python code with AI safely: find code smells, check that tests pin the behavior, and let an agent apply one refactoring at a time. REAL PYTHON How to Do a Binary Search in Python Use the bisect module to do a binary search in Python, then implement this classic algorithm yourself, both iteratively and recursively. REAL PYTHON Build and Deploy Python Inside Snowflake Take Python workflows from development to deployment without leaving Snowflake. With the Posit Team Native App, develop, deploy, and govern with integrated AI assistance inside Snowflake’s security boundary. No data movement. No separate infrastructure. Start your free 30-day trial. POSIT sponsor Django Race Conditions: Unique Constraints The first in a series on Django race conditions: how to handle unique constraints in your forms so users don’t get a 500 response. TIM SCHILLING Join in the PSF Year-End Fundraiser & Membership Drive! PYTHON SOFTWARE FOUNDATION PyCon US 2027: Call for Proposals Now Open! PYCON.BLOGSPOT.COM Black Friday Giveaway: Win 3 Years of Real Python Enter for a chance to win three years of Real Python plus all four Real Python books, or one of the runner-up prizes: 50% off an annual membership or 30% off the Python book bundle. It’s free to enter with a Real Python account, and entries close Friday, November 27 at 11:59 pm PT. REAL PYTHON Articles & Tutorials How to Find and Fix N+1 Queries in Django N+1 queries are one of those Django performance problems that can hide in plain sight. A page might look fine with five rows in development and then suddenly make hundreds of database queries in production. This tutorial shows you how to find and fix these kinds of queries. CODE WITH STEIN The Rise and Fall of Python’s Benevolent Dictator This article describes the journey of Guido van Rossum who wrote Python over a 1989 Christmas break. By 2018 it ran AI and the web, and a fight over the walrus operator (PEP 572) drove him to resign. BRUCE LI Python’s Experimental JIT to Be Removed You may have already seen the news that the JIT is being removed from the main branch of CPython. This article covers the details and the history behind the decision. JOE BROCKMEIER How the Python Ecosystem Responded to the eMudhra Intermediate Compromise In October there was a compromise to a Certificate Authority. This post talks about how the PSF and other parts of the Python community addressed the issue. PYTHON SOFTWARE FOUNDATION Nuitka: Compile Python Into a Standalone Executable Learn to compile Python into a standalone executable with Nuitka. Compare standalone and onefile builds, test speed, and see when PyInstaller fits better. REAL PYTHON Quiz: Nuitka: Compile Python Into a Standalone Executable REAL PYTHON Scientific Python: Using SciPy for Optimization Learn how the SciPy ecosystem differs from the SciPy library, then install SciPy and use its clustering and optimization modules in Python. REAL PYTHON Faster CI With Orchestrated pytest Workers How a shared test queue and interruptible workers let the people at Close add cheaper parallelism to Python Continuous Integration. ALEC ROSENBAUM How to Set Up a Python Project for Agentic Coding Learn how to set up a Python project for agentic coding, with the tests, types, and hooks that give AI coding agents fast feedback. REAL PYTHON Quiz: How to Set Up a Python Project for Agentic Coding REAL PYTHON funkycache: A Python Library to Cache Functions in SQLite This post describes funkycache, a new SQLite-backed caching library. It describes why Alex wrote it and how it works. ALEX CHAN Stricter Checks for Uploaded Distributions on PyPI PyPI has added new checks that can reject uploaded source distributions to provide more package security. WILLIAM WOODRUFF Projects & Code django-rosetta: Django App That Eases the Translation GITHUB.COM/MBI pytest-glow-report: HTML and JSON Reports for pytest GITHUB.COM/GODHIRAJ-CODE • Shared by Dhiraj Das django-ninja-expose: Ninja APIs With a Decorator GITHUB.COM/SWARFTE fastapi-restly: REST With FastAPI and SQLAlchemy GITHUB.COM/RJPRINS • Shared by Rutger Prins pencil-puzzles: Generate, Solve, and Rate Logic Puzzles Fast GITHUB.COM/EMIEKS • Shared by Emil Events Weekly Real Python Office Hours Q&A (Virtual) November 25, 2026 REALPYTHON.COM Python E-Commerce Forum November 26 to November 29, 2026 CODEHUT.CO.UK Build a Multi-Agent Travel Assistant With Google ADK November 26, 2026 MEETUP.COM PyDelhi User Group Meetup November 28, 2026 MEETUP.COM PyLadies Asia Conference 2026 November 29 to November 30, 2026 PYLADIES.KR Happy Pythoning!This was PyCoder’s Weekly Issue #762.View in Browser » [ Subscribe to 🐍 PyCoder’s Weekly 💌 – Get the best Python news, articles, and tutorials delivered to your inbox once a week >> Click here to learn more ]