This book sounds cool. I reviewed two manuscripts for Manning “100 Mistakes” books - for Go and Java. Based on my experience reviewing them, I’ll share my thoughts on what I liked and didn’t like.
With the Go book, I liked that the author kept things short. Each “mistake” I could read in about a minute. If I wanted to fully grok it by re-reading it a few times and running the code myself, it was no more than 5 minutes each, maybe 10-15 for some more complex ones. The author also focused on things that were low level, so things that many Go devs could relate to. Variable shadowing mistakes, string handling quirks, slice handling quirks, and error handling come to mind.
Overall, I really liked it. I know you probably want to go for your own style, but I do recommend giving the final published version a glance if you’re looking for inspiration. Based on my experience working with Manning, they’re willing to open up their entire library to you to help you create the content you’re contracted to create for them. So, you could take advantage of that.
With the Java book, I found it a bit dry and unmemorable. I was seeing a lot of stuff that was either too basic for me to be interested in (where I felt it was hard to make a “mistake” with it as long as you read the docs) or it was very verbose content that was about arranging your project and setting up various tools like linters and annotation processors. That’s going to get out of date, so I felt it didn’t make much sense being there. The one thing I remember the most is a chapter on creating your own static code analysis plugin. That was cool, but then again, does it make sense for an entire chapter to be a tutorial like that in a “100 Mistakes” book? Probably not, so that still felt weird to me.
Based on those experiences, I think my ideal “100 Python Mistakes” book would be one that kept each mistake short and sweet and focused on language fundamentals (instead of subjective coding styles, project set up, favorite libraries, etc).
With regard to popular libraries, the exception I think I would make for Python is that I’d be okay with a “mistake” like “don’t implement data frames, use x” because Python doesn’t have a lot of the things it does best in its standard library. Instead, it’s considered best practice to look to particular popular 3rd party libraries for these use cases. Pandas for data frames comes to mind. But, don’t show me how to use x. That would take too long to read, get out of date quickly, and veer into being off topic. Just quickly let me know of its existence, with maybe a quick comparison between the verbose, error-prone monstrosity I’d have to write if using vanilla Python vs. the short, efficient, code I’d be able to write by using x.
With regard to Python language fundamentals, I know that as someone who plans to skill up on Python soon, there are a few things I’m interested in a few things about Python programming. But, I don’t know if they’re best for a “100 Mistakes” book or a book dedicated to learning Python programming in general. They are:
- How to do async programming (mistakes could be “don’t block threads more often than you need to” etc)
- How to stream data (mistakes could be “don’t store more data in memory than you need to” etc)
- How to package Python applications (here be dragons - this is probably so hard to do in a book, I know. Also, Manning already has a book dedicated to this)
- How to Dockerize Python applications, be they CLIs or long lived processes like web apps (maybe out of scope)
- Anything that modern versions of Python has retroactively made into anti-patterns (mistakes could be “don’t do x because Python y introduced z” etc)
Best of luck!