Issue #679

Regexes, Deep Copy, Enum, and More

April 29, 2025

Regexes, Deep Copy, Enum, and More
#679 – APRIL 29, 2025 VIEW IN BROWSER
The PyCoder’s Weekly Logo
Regex Affordances
A tour of some real code showing little-used power features of the Python regular expression module, including verbose regex syntax, calling re.sub() with a function reference, and more.
NED BATCHELDER

Shallow vs Deep Copying of Python Objects
What’s the difference between a shallow copy and a deep copy of a Python object? Learn how to clone arbitrary objects in Python, including your own custom classes.
REAL PYTHON

Quiz: Shallow vs Deep Copying of Python Objects
REAL PYTHON

Learn AI In 5 Minutes A Day
Everyone talks about AI, but no one has the time to learn it. So, we found the simplest way to learn AI as quickly as possible: The Rundown AI. It’s the most trusted AI newsletter, with 1M+ readers and exclusives with AI leaders like Mark Zuckerberg, Demis Hassibis, Mustafa Suleyman, and more →
THE RUNDOWN AIsponsor

Module enum Overview
This article gives an overview of the tools available in the module enum and how to use them, including Enum, auto, StrEnum, Flag, and more.
RODRIGO GIRÃO SERRÃO • Shared by Rodrigo Girão Serrão

Call for EuroPython 2026 Host Venues
EUROPYTHON-SOCIETY.ORG

PEP 787: Safer Subprocess Usage Using t-strings (Postponed to 3.15)
PYTHON.ORG


Articles & Tutorials


Getting Started With Python IDLE
In this tutorial, you’ll learn how to use the development environment included with your Python installation. Python IDLE is a small program that packs a big punch! You’ll learn how to use Python IDLE to interact with Python directly, work with Python files, and improve your development workflow.
REAL PYTHON

15k Lines of Verified Cryptography Now in Python
Over the last two years there has been an ongoing project to automatically populate the cryptographic libraries in the Python build, helping to ensure their validity and security. This project is now complete, and has been done without effecting the releases along the way.
JONATHAN PROTZENKO

MySQL Databases and Python
In this video course, you’ll learn how to connect your Python application with a MySQL database. You’ll design a movie rating system and perform some common queries on it. You’ll also see best practices and tips to prevent SQL injection attacks.
REAL PYTHON course

Python’s New t-strings
Using f-strings is a readable way of building output, but there are situations where they can’t be used because the contents need to be verified before being string-ified. The new t-strings, coming in 3.14, are a solution to this problem.
DAVE PECK

How to Run Python in Production
This post is a series of recommendations for running Python in a production environment. It includes package management, linters, preventing secrets being leaked, and much more.
ASHISH BHATIA

Feedback Loops in Python
How fast can we get useful feedback on the Python code we write? Learn different techniques to get quick results to better understand if your code is doing what it is supposed to.
DAVIDVUJIC.BLOGSPOT.COM • Shared by David Vujic

Django Admin Theme Roundup 2025
The Django Admin isn’t the prettiest thing out there but there are third party libraries that improve its appearance. This post talks about some of the most popular ones.
ADAM HILL

Choosing the Right Python Task Queue
Python has great options for task queues. Choosing between Celery and RQ isn’t an easy decision. Jump in and learn how each option compares!
JUDOSCALE.COM • Shared by Jeff Morhous

Django Ledger: Accounting With Python
Talk Python interviews Miguel Sanda about Django Ledger, a library you can use to build your own accounting system.
KENNEDY & SANDA

Frankenstein’s __init__
The untold story of the craziest __init__ Ohad has ever seen.
OHAD RAVID


Projects & Code


Brought to you by Real Python for Teamssponsor
Online Python training created by a community of experts. Give your team the real-world Python skills they need to succeed →

mininterface: Interface to Python GUI, TUI, CLI, & Web
GITHUB.COM/CZ-NIC

asv: Benchmarking Tool With Web-Based Reporting
GITHUB.COM/AIRSPEED-VELOCITY

PyFunctional: Data Pipelines With Functional Programming
GITHUB.COM/ENTILZHA

Robyn: Async Python Web Framework With a Rust Runtime
GITHUB.COM/SPARCKLES

msgspec: Fast Serialization and Validation Library
GITHUB.COM/JCRIST

📆🐍 Upcoming Python Events


Weekly Real Python Office Hours Q&A (Virtual)
April 30, 2025

PyCamp España 2025
May 1 to May 5, 2025

Canberra Python Meetup
May 1, 2025

Sydney Python User Group (SyPy)
May 1, 2025

Michigan Python May Meeting
May 1 to May 2, 2025
Happy Pythoning!
Copyright © 2025 PyCoder’s Weekly, All rights reserved.