Mutable default args: the Python trap that gets everyone once.
It looks like a fresh list every time you call it. It isn't.
7 min read
Keep Shipping!
Nick
Index
All articles
Next
Building a lightweight rate limiter for a Django API
Previous
Python sets, and when to reach for one.
Monitoring
Monitor your Django app
Know when your APIs are slow, erroring, or down before your users do.
Try Watchdock free ▶About the author

Nick Langat
Product-minded software engineer obsessed with systems design, performance, and AI pipelines.