Python 2.x coverage here has been updated to include features such as dictionary and set comprehensions that were formerly for 3.X only, but have been back-ported for use in 2.7.
Python 3.x coverage has been augmented for new yield and raise syntax; the
__pycache_ bytecode model; 3.3 namespace packages; PyDoc's all-browser
mode; Unicode literal and storage changes; and the new Windows launcher shipped with 3.3.
Assorted new or expanded coverage for JSON, timeit, PyPy, os.popen, generators, recursion, weak references,_mro_,_iter_, super,_slots_, metaclasses, descriptors, random. Sphinx, and more has been added, along with a general increase in 2.x compatibihty in both examples and narrative.
This edition also adds a new conclusion as Chapter 41 (on Python's evolution), two new appendixes (on recent Python changes and the new Windows launcher), and one new chapter (on benchmarking: an expanded version of the former code timing example). See Appendix C for a concise summary of Python changes between the prior edition and this one, as well as links to their coverage in the book. This appendix also summarizes initial differences between 2.X and 3.X in general that were first addressed in the prior edition, though some, such as new-style classes, span versions and simply become mandated in 3.X (more on what the X's mean in a moment).
Per the last bullet in the preceding list, this edition has also experienced some growth because it gives fuller coverage to more advanced language features-which many of us have tried very hard to ignore as optional for the last decade, but which have now grown more common in Python code. As we'll see, these tools make Python more powerful, but also raise the bar for newcomers, and may shift Python's scope and definition. Because you might encounter any of these, this book covers them head-on, instead of pretending they do not exist.
Despite the updates, this edition retains most of the structure and content of the prior edition, and is still designed to be a comprehensive learning resource for both the 2.X and 3.x Python lines. While it is primarily focused on users of Python 3.3 and 2.7-the latest in the 3.X line and the likely last in the 2.X line-its historical perspective also makes it relevant to older Pythons that still see regular use today.
Though it's impossible to predict the future, this book stresses fundamentals that have been valid for nearly two decades, and will likely apply to future Pythons too. As usual, I'll be posting Python updates that impact this book at the book's website described ahead. The "What's New" documents in Python's manuals set can also serve to fill in the gaps as Python surely evolves after this book is published.