Discussion forum for David Beazley

Post errata topics for Python Essential Reference fourth Edition

I didn’t see this in the Errata online - but after reading the section on Decorators ( page 101) where inline functions were dynamically define and return, I thought it strange that the examples in the Documentation Strings section (page 113- 114 ) that the “def” was missing on the definition of the call function



def wrap(func):
call(*args, **kwargs):
have been

def wrap(func):
def call(*arge, **kwargs):

This shows up once on page 113, and twice on page 114

Looks like leading spaces were removed in my previous post, but looking at the book - I was trying to copy the indentation from the book

Another potential errata on page 188 on the python clear command

cl(ear) [bpnumber [bpnumber …]]

Clears a list of breakpoint numbers. If breakpoints are specified, all breaks are cleared.

Looks like we are missing a “no”, and the second sentence should read
If no breakpoints are specified, all breaks are cleared

The official errata page for the 4th edition is at http://www.dabeaz.com/errata.html. The 5th edition (in progress) is sufficiently different, it’s hard for me to know how much of the errata will apply to that. However, feel free to keep posting things here.