Fantastic Bugs (and how I find them)
Zac Hatfield-Dodds (~Zac-HD) |
I'm a maintainer of Hypothesis, the property-based testing library, and working on a PhD about better ways to find bugs in our code. So I've seen some amazing bugs - and I want to share the highlights.
We'll look at weird behaviour featuring unicode, datetimes, numbers and not-a-numbers; in libraries and in the language itself. I'll explain how I decide where to look, and the 'property based' attitude to specifying what code should always or never do.
We'll see some cool performance optimisations, misunderstandings, unexpected implementation details, and a couple of genuine bugs. Reflecting on the difference can help us understand why bugs happen, and if we're lucky even how to prevent, find, and fix them!
You'll get more out of this talk if you're comfortable with Python. I won't explain the details of Unicode, datetimes, Numpy, or Python syntax - but if you don't know them, you can still learn from the way of thinking. In other words, I'm aiming this talk at "advanced" level but it should still be fun for intermediate Pythonistas too :-)
Zac's modest goal is to help everyone write better code - mostly via bug-finding tools.
He spends his time contributing to Hypothesis, Pytest, and other open-source projects; supporting the Python community as a PSF Fellow; and working on HypoFuzz and his PhD at the Australian National University. If you can't get to him via a computer, Zac can probably be found with a good book, a pile of chocolate, a long walk in the bush... or all three!