Python Trending Weekly
ISSUE 104

Python Considering Adding Virtual Threads?

2025-05-31 Season 4

TL;DR

Pyrefly and ty square off as the new type checkers to beat, Pandas plans to swap NumPy for the faster PyArrow, and a virtual threads proposal sparks discussion alongside a 70-line MCP agent.

Articles 28
🐍

In this issue

× 28
01 Pyrefly vs. ty: Comparing Python's Two New Rust-Based Type Checkers blog.edward-li.com

Both Meta's Pyrefly and Astral's ty are Python type checking tools developed based on Rust, and they both appeared at this year's PyCon Typing Summit. The article introduces their differences in development background, design philosophy, technical features and performance.

02 Single process, multiple interpreters, no GIL contention - pre-Python3.12 basisrobotics.tech

How to implement single-process multi-interpreter execution in Python versions before 3.12? The article introduces using dlopen and dynamic library loading mechanisms to bypass Python's single interpreter limitation. This approach allows the robotics framework Basis to run multiple Python instances in the same process space while avoiding GIL contention, providing an innovative architectural solution for high-performance robotics systems.

03 Why, in 2025, do we still need a 3rd party app to write a REST API with Django? djangoproject.com

This article from the official Django blog raises a question: Do we really need third-party libraries to build REST APIs with Django? It introduces how to use Django's built-in generic class views and form system to implement complete CRUD REST API functionality with less than 100 lines of code.

04 Introducing Pyrefly: A new type checker and IDE experience for Python engineering.fb.com

Meta officially announced the alpha version of Pyrefly, which can perform type checking at a speed of 1.8 million lines of code per second, supporting IDE-first development experience and automatic type inference. The article explains why it was developed to replace Pyre, the principles behind it, and future development plans.

05 Python Pandas Ditches NumPy for Speedier PyArrow thenewstack.io

Pandas is about to release version 3.0, which will use PyArrow to replace NumPy as the default engine for handling columnar data loading and reading. PyArrow provides columnar storage, supports Copy on Write mode, and has significant advantages in memory usage and reading speed.

06 Tiny Agents in Python: an MCP-powered agent in ~70 lines of code huggingface.co

Hugging Face released "Tiny Agents", which can enable large language models to call external tools and APIs through the MCP protocol, thereby achieving more powerful functionality. The article demonstrates its usage and powerful capabilities.

07 Narwhals: Unified DataFrame Functions for pandas, Polars, and PySpark codecut.ai

Narwhals is a lightweight compatibility layer that unifies functions from mainstream DataFrame libraries like pandas, Polars, and PySpark, avoiding the complexity of writing separate code for each library and improving code portability and reusability.

08 DumPy: NumPy except it's OK if you're dum dynomight.net

The author proposes redesigning NumPy with loop and indexing syntax, solving the complexity of high-dimensional array operations by compiling loop syntax into vectorized operations. DumPy implements automatic vectorization based on JAX's vmap, allowing intuitive loop syntax to achieve GPU-accelerated performance, significantly reducing the cognitive burden of multi-dimensional array programming.

09 Beyond Query Optimization: Aurora Postgres Connection Pooling with SQLAlchemy & RDSProxy eng.lyft.com

Lyft's engineering team shares their practical experience migrating from application-level connection pooling to AWS RDSProxy proxy connection pooling. It details the importance of connection pooling, SQLAlchemy configuration methods, and how RDSProxy solves the problem of connection number surge during application scaling.

10 Validating a new project mostlypython.com

The author open-sourced py-bugger, a tool that introduces specific types of bugs to assist in debugging education. He communicated face-to-face with other developers at PyCon's open spaces, discovered some new use cases and issues, emphasizing the importance of getting feedback through open spaces in the early stages of a project.

11 Attention Wasn't All We Needed stephendiehl.com

Introduces a series of important technical improvements that have emerged in the Transformer model field since the famous "Attention Is All You Need" paper was published. The author uses the PyTorch framework and concise code examples to explain the core ideas of 14 important technologies and how they improve model inference speed and memory efficiency.

12 Writing that changed how I think about PL bernsteinbear.com

The author shares more than 10 articles in the field of programming languages and compilers that have had a significant impact on their thinking, including garbage collector implementation, optimizer instruction rewriting, abstract domains and Z3 usage, correctness proofs of register allocation, regular expression engines, automatic differentiation, SSA form implementation, and more.

🐿️Projects & Resources

01 agenticSeek: Fully Local Manus AI github.com

A 100% local alternative to Manus AI that supports voice, autonomous web browsing, code writing and task planning, with all data staying on local devices. (star 13.5K)

02 django-allauth: Integrated set of Django applications addressing authentication codeberg.org

A Django application suite that provides complete user authentication, registration, account management, and third-party social account authentication functionality. Supports multiple authentication schemes (username or email login), multiple account verification strategies, and integrates OAuth 1.0/2.0, OpenID Connect, SAML 2.0 and other protocols.

03 Ghost-Downloader-3: A cross-platform fluent-design AI-boost multi-threaded downloader github.com

A cross-platform multi-threaded downloader developed based on Python, adopting Fluent Design style, with AI intelligent acceleration functionality, IDM-style intelligent chunked downloading, browser extension support and plugin system, supporting Windows, macOS and Linux platforms. (star 2.6K)

Beautiful downloader

04 vectorvfs: Your Filesystem as a Vector Database github.com

A lightweight Python package that converts Linux file systems into vector databases, storing vector embeddings directly outside files through VFS extended attributes, without requiring external indexes or database services.

05 LivePortrait: Bring portraits to life! github.com

Kuaishou's open-source portrait animation generation tool that supports efficient portrait animation creation, with stitching and redirection control functions, supporting portrait and animal modes, providing Gradio interface and one-click installation package. (star 15.5K)

Bringing world famous paintings to life

06 pgmpy: Python Library for Causal and Probabilistic Modeling using Bayesian Networks github.com

A professional Python causal and probabilistic modeling library based on Bayesian networks. Provides a complete set of probabilistic graphical model tools, suitable for machine learning and statistical analysis fields. (star 3K)

07 MaiBot: Cyber Netizen for Group Chat github.com

An interactive intelligent agent based on large models, focusing on group chat scenarios. Features intelligent conversation, real-time thinking, emotional expression, persistent memory and dynamic personality systems. (star 2.5K)

08 magentic-ui: A research prototype of a human-centered web agent github.com

Microsoft's open-source human-computer collaborative web agent research prototype that can automate web tasks while maintaining user control, supporting collaborative planning, collaborative execution, action protection, plan learning and parallel task execution. (star 4.7K)

09 vibe-draw: Turn your roughest sketches into stunning 3D worlds by vibe drawing github.com

Converts rough hand-drawn sketches into beautiful 3D models. Supports free drawing, AI enhancement optimization, one-click 3D conversion, world building and model export functions. Developed based on Next.js, Three.js and FastAPI. (star 1.8K)

Nice full-stack + AI project

10 airweave: Airweave lets agents search any app github.com

This intelligent agent can connect various applications, productivity tools and databases, converting their content into searchable knowledge bases and providing services to agents through standardized interfaces. (star 2.5K)

11 flowshow: Just a super thin wrapper for Python tasks that form a flow github.com

It provides @task decorators to track and visualize function execution flows. Supports retry mechanisms, logging, context managers and interactive visualization interfaces.

12 ai-baby-monitor: Local Video-LLM powered AI Baby Monitor github.com

An intelligent baby monitoring system based on local video large models that monitors in real-time through cameras, performs real-time analysis according to safety rules, and issues gentle reminder sounds when violations of safety rules are detected.

🐢Podcasts & Videos

01 PyCon US 2025 Video List youtube.com

This year's PyCon US videos were released very early! See if there are any topics that interest you?

02 PyTexas 2025 Video List youtube.com

The PyTexas event in Texas, USA has released 21 presentation videos.

🥂Discussions & Questions

01 Add Virtual Threads to Python discuss.python.org

Python core developer Mark Shannon (yes, the proposer of Faster CPython, who was recently laid off by Microsoft) proposed the idea of adding virtual threads to Python, believing that virtual threads can handle concurrency better than async/await. The post introduces the advantages and implementation methods of this approach, sparking widespread discussion in the community.

02 What CPython Layoffs Taught Me About the Real Value of Expertise reddit.com

Microsoft's layoffs of the CPython and TypeScript compiler teams triggered the author's deep thinking about the value of technical expertise. Should we focus on output rather than architecture, on impact rather than elegance? How to balance technical depth with business value?

🐧 Past Reviews

Python Weekly #54: ChatTTS Powerful Text-to-Speech Model (2024.06.08)

Python Weekly #4: Python 2023 Language Summit (2023.05.31)

ESC
↑↓ select · ↵ open175 issues