What This Book Covered
You are reading about a previous, old version of this book. The third edition of this book (released in November, 2024) is focused exclusively on Python 3, up to and including version 3.13.
Many of the original items from the first edition have been revised and included in the second and third editions, but they have undergone substantial updates. For some items my advice has completely changed between the three editions of the book due best practices evolving as Python has matured.
If, for whatever reason, you’re still primarily using Python 2, despite its end-of-life in April 2020, the first edition of the book (released in March, 2015) may be more useful to you.
Translations are available in 日本語, Deutsche, 简体中文, 繁体中文, Русский, Polszczyzna, 한국어, Português
Секреты Python
The publishing house Вильямс has translated and released a Russian version of Effective Python. You can buy the book online from Ozon and learn more on the publisher website.
Python Eficaz
The publishing house Novatec Editora has translated and released a Portuguese version of Effective Python. You can buy the book directly from the publisher.
Effective Python 简体中文
The publishing house 机械工业出版社 (China Machine Press) has translated and released a Chinese (Simplified) version of Effective Python. You can buy the book directly from the publisher or get it on Amazon.cn.
Effective Python 파이썬 코딩의 기술
The publishing house Gilbut Inc. has translated and released a Korean version of Effective Python. The publisher’s website links to many different retailers online where you can buy the book.
Effective Python 日本語
The publishing house O’Reilly Japan has translated and released a Japanese version of Effective Python. You can buy the book directly from the publisher or get it on Amazon.jp.
Efektywny Python
The publishing house Helion has translated and released a Polish version of Effective Python. You can buy the book directly from the publisher.
Effektiv Python programmieren
The publishing house mitp-Verlag has translated and released a German version of Effective Python. You can buy the book directly from the publisher or get it on Amazon.de (including Kindle edition).
Talk Python To Me Podcast
I was invited on to the Talk Python To Me Podcast to talk about Effective Python. You can read the full transcript here or listen to the audio embedded below. Thanks to Michael Kennedy for being such a welcoming host.
Effective Python 中文版
The publishing house 碁峰 (Acer Peak) has translated and released a Chinese (Traditional) version of Effective Python. You can buy the book directly from the publisher or get a digital edition on Google Play.
Live Lessons Video
I worked with Addison-Wesley to produce a video version of the book Effective Python. You can view samples and buy the video on the publisher’s website.
It includes 5 hours of video, covering 32 items from the book in six lessons. The content is primarily me using a source code editor to write Python programs that demonstrate the items from the book.
Talk at PyCon Montréal
I gave a talk at PyCon Montréal entitled “How to Be More Effective with Functions”.
Item 40: Consider Coroutines to Run Many Functions Concurrently
Threads give Python programmers a way to run multiple functions seemingly at the same time. But there are three big problems with threads:
The Book Is Published
Printed, physical copies of the Effective Python book are now for sale! Follow this link to buy directly from the publisher (free shipping in the USA). The publisher also has ePub and PDF versions available. Follow this link to buy from Amazon. Amazon also has a Kindle edition available.
Digital Editions Now Available
Digital editions of Effective Python are now available. Follow this link to buy the ePub or PDF version. Follow this link to buy the Kindle edition. The print copy is due out on March 6th.
Item 34: Register Class Existence with Metaclasses
A common use of metaclasses is to automatically register types in your program. Registration is useful for doing reverse lookups, where you need to map a simple identifier back to a corresponding class.
Item 53: Use Virtual Environments for Isolated and Reproducible Dependencies
Building larger and more complex programs often leads you to rely on various packages from the Python community. You’ll find yourself running pip to install packages like pytz, numpy, and many others.
The problem is that by default pip installs new packages in a global location. That causes all Python programs on your system to be affected by these installed modules. In theory, this shouldn’t be an issue. If you install a package and never import it, how could it affect your programs?
Item 17: Be Defensive When Iterating Over Arguments
When a function takes a list of objects as a parameter, it’s often important to iterate over that list multiple times.
The Rough Cut Is Online
Can’t wait until next year for the book to be published? The rough cut is now available on Safari Books Online. This is an early preview of the full content of the book before editing has been completed.
Now Available for Preorder
Effective Python is now available for preorder on Amazon. Follow this link to buy your copy in advance. It will ship in early 2015 once the book is published.
Final Draft Done
The final draft of the book is done. It’s 55,000 words, 250+ pages, 8 chapters, 59 items. Reviewers spent a lot of time looking over earlier drafts to ensure that the book will be useful. Now it’s off to production to be turned into a printable layout.
Welcome
This website is now live! Here you’ll find updates about my progress towards Effective Python‘s eventual publishing by Addison-Wesley. You can find other books from the Effective series in Pearson’s online store.









