Brett Slatkin
Brett Slatkin
Reported by Mr. Kurokawa. This sentence and the preceding example: > It’s better not to leak loop variables, so I recommend using assignment expressions only in the condition part of...
This sentence on page 164: "However, these parameters are not required for object instance initialization." In the print version the word "object" is in fixed width font. But it shouldn't...
Got this one via an email. Libor writes: > I have a small nitpick regarding bytes indexing - in the code example preceding paragraph starting "The bytearraytype...", you should also...
From Nicholas via email: > 2. On page 94, you say "Sometimes you need to use a non-static type as a keyword argument's default value." This doesn't match the terminology...
Another reported by Toshi: ``` TypeError: open_picture() missing 1 required positional argument: 'profile_path' ``` There should be a line continuation character in there for the two lines of the stringified...
Reported by Toshi ``` Traceback ... UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb8 in position 0: invalid start byte ``` There should be one in there between the two lines...
This code snippet: ``` try: result = careful_divide(x, y) except ValueError: print('Invalid inputs') else: print('Result is %.1f' % result) ``` The `print` at the end should be `print(f'Result is {result:.1f}')`
Page 82, Item 20, line 11 from top ``` try: return a / b except ZeroDivisionError as e: raise ValueError('Invalid inputs') ``` The "as e" isn't necessary anymore because of...
Page 37, Item 10, line 2 from top "I do this by fetching the count from the fruit_basket" should be read as "I do this by fetching the count from...
Once you know how far behind you are with #3, it'd be nice if a reader can elect to zip forward to sync with the writer and skip a bunch...