Python Trending Weekly
ISSUE 113

Replacing Async/Await with Virtual Threads

2025-08-02 Season 4

TL;DR

Can virtual threads replace async/await? A manifesto that kicked off big debate, plus CPython 3.14's remote debugging unveiled, an architecture face-off of DeepSeek-V3 vs Kimi K2, and a PyPI phishing incident as a warning.

Articles 12 Projects 12 Media 1
🦄

Articles & Tutorials

× 12
01 Checking Out CPython 3.14's Remote Debugging Protocol rtpg.co

Python 3.14's new sys.remote_exec() function lets you inject code into a running process without a restart or source code changes. You can perform remote debugging with the python -m pdb -p pid command to check status, get stack traces, and even start an interactive session at runtime. This standardized injection mechanism significantly lowers the bar for developing debugging tools.

02 Operating Inside the Interpreted: Offensive Python trustedsec.com

This article reveals Python's potential as an offensive security tool in a Windows environment. It shows how to easily deploy Python via the Microsoft Store or offline and use the ctypes library to call Win32 APIs directly for low-level system operations.

03 From Async/Await to Virtual Threads lucumr.pocoo.org

Armin Ronacher explores the future of concurrent programming in Python, proposing virtual threads as a replacement for async/await! He envisions a world with structured concurrency and a cleaner API that eliminates the 'function color' problem, handing the complexity of concurrency back to the interpreter. This would allow developers to write concurrent code in a simpler, more intuitive way.

04 Following up on the Python JIT lwn.net

How is the CPython JIT compiler being developed? This article breaks down the process, explaining how techniques like tracing and a 'copy-and-patch' mechanism are used to compile only the most frequently executed code paths. It also covers how the JIT handles tricky issues like memory management, debugging, and performance analysis.

05 asyncio: A Library with Too Many Sharp Corners sailor.li

Ever been burned by asyncio? The author sharply points out its three major design flaws: a messy cancellation mechanism, weakly-referenced tasks, and callback-style I/O, which can easily lead to deadlocks or tasks that mysteriously disappear. Looking for a more elegant concurrency solution? The author recommends Trio/AnyIO.

06 Building Autonomous Systems: A Guide to Agentic AI Workflows digitalocean.com

How can we get AI agents to work autonomously like humans? This article demystifies their core workflow: through autonomous planning, tool use, reflection, and multi-agent collaboration, they can achieve capabilities beyond traditional automation. The piece also explores how frameworks like LangChain and AutoGen bring AI to life and how to design reliable feedback mechanisms.

Agentic Workflow
07 The Big LLM Architecture Comparison open.substack.com

This article systematically compares the architectures of various large models like DeepSeek-V3 and Llama 4. It dives deep into the evolution from multi-head attention to grouped-query attention and multi-head latent attention, and explains how Mixture-of-Experts models achieve efficient inference through sparse activation.

08 A Better Alternative to Shell Scripts with Python, uv, and pytest hamatti.org

Learn how to use uv and PEP 723's inline metadata feature to develop self-contained Python scripts. Not only can you automatically manage dependencies in a temporary virtual environment, but you can also integrate pytest for testing, making your automation scripts more reliable and easier to maintain.

09 Incident Report: Phishing Attack blog.pypi.org

PyPI was hit by a phishing attack. Attackers used the lookalike domain pypj.org to create a fake website, tricking users into leaking their credentials. This led to malicious code being injected into packages like num2words. The incident is a stark reminder of the importance of enabling two-factor authentication (2FA) and using hardware security keys.

10 Can You Execute Arbitrary Python Code from Only a Comment? hacktron.ai

Execute arbitrary Python code with just a single comment? This article reveals a clever attack technique that constructs a 'polyglot' file—one that's both a valid Python script and a ZIP archive—to successfully exploit an interpreter feature and achieve code injection!

11 How the Application and Request Contexts Work in Python Flask blog.appsignal.com

Ever wonder why Flask's global objects like request work flawlessly in a multi-threaded environment? This article demystifies Flask's core context mechanism, explaining how the application and request contexts work together to ensure data isolation.

12 Is AI Leaving the Python Community Behind? georgiker.com

AI's boom owes a lot to Python, but are AI companies starting to cannibalize the community? The article points out that many companies are reaping the benefits of the Python community while giving little back. As 'AI crash course' topics dominate tech conferences and entry-level jobs dwindle due to AI, we have to ask: in our rush to embrace AI, are we undermining the very foundations of the Python community?

🐿️

Projects & Resources

× 12
01 mediacms: A modern, fully featured open source video and media CMS github.com

A full-featured video and media CMS built with Python/Django and React. You can set up a small to medium-sized video and media portal in minutes. (3.6K stars)

02 darkdump: Open Source Intelligence Interface for Deep Web Scraping github.com

An OSINT (Open Source Intelligence) tool developed in Python for deep web investigations. Input a search query, and it scrapes relevant .onion sites via Ahmia.fi to extract emails, metadata, keywords, images, and social media info. (1.3K stars)

03 ii-agent: A New Open-Source Framework to Build and Deploy Intelligent Agents github.com

An open-source intelligent assistant that supports models like Claude and Gemini. It provides a CLI, a frontend, and supports local, Docker, and E2B execution environments. Core capabilities include research, fact-checking, content generation, data analysis, software development, and workflow automation. (2.8K stars)

04 copyparty: Portable File Server github.com

A portable file server with resumable uploads/downloads, deduplication, WebDAV, FTP, TFTP, zero-config setup, media indexing, and thumbnail generation. All features are packed into a single, dependency-free file, supporting multiple protocols and mobile apps. (17.1K stars)

copyparty: Portable File Server
05 ai-cookbook: Examples and Tutorials to Help Developers Build AI Systems github.com

An AI development cookbook that guides you in building AI systems. It provides code snippets that can be easily integrated into your own projects, covering topics like Python, OpenAI, agents, LLMs, and Anthropic. (2.5K stars)

06 agno: Full-Stack Framework for Building Multi-Agent Systems github.com

A full-stack framework for developing multi-agent systems with memory, knowledge, and reasoning capabilities. It supports five levels of complexity, from simple tools to sophisticated agent teams, and offers a unified model interface, high-performance architecture, and built-in search and storage. (31K stars)

07 abogen: Generate Audiobooks from EPUBs, PDFs, and Text github.com

A powerful text-to-speech tool that quickly converts ePub, PDF, or text files into high-quality audio with synchronized subtitles. It supports multiple languages and voices, making it perfect for creating audiobooks, video voiceovers, and more.

08 CCPlugins: Claude Code Productivity Plugins github.com

A collection of productivity commands designed for the Claude Code CLI. It automates development workflows, checks code quality, manages sessions, and includes useful commands for cleaning projects, smart commits, code formatting, test fixing, and code reviews, making your AI assistant feel more like a senior engineer.

09 LangExtract: Structured Information Extraction Library github.com

An open-source library from Google that uses large models to extract structured information from unstructured text. It features precise source attribution, reliable structured output, optimized handling of long documents, and interactive visualization, supporting both cloud and local models. (1.3K stars)

10 PicTex: A Powerful Python Library to Create Beautifully Styled Text Images github.com

A Python library built on the Skia graphics engine that provides a clean and fluent API for creating beautiful text images. It supports rich styles like gradients, shadows, and outlines, and features automatic font fallback, advanced typography, and both vector and raster output. Perfect for social media, video overlays, and digital art.

11 html-to-markdown: HTML to Markdown Converter github.com

Converts HTML to Markdown format. It supports the full range of HTML5 elements, enhanced table handling, type safety, metadata extraction, and streaming. It also provides a CLI tool and custom converters, with over 91% test coverage.

12 erys: Terminal Interface for Jupyter Notebooks github.com

A tool that lets you open, create, edit, run, and save Jupyter Notebooks right in your terminal. It uses a Textual-based interface, executes code via jupyter_client, supports syntax highlighting for various file formats, and can even render images and HTML output.

🐢

Podcasts & Videos

× 1
01 Episode #513 - Stories from Python History talkpython.fm

Barry Warsaw, Paul Everitt, Carol Willing, and Brett Cannon join the show to share stories from Python's history, including how 'import this' came to be and what the very first PyCon was like.

ESC
↑↓ select · ↵ open175 issues