Overview
Explore the power of static analysis for improving Python code quality in this 40-minute EuroPython Conference talk. Discover how to find bugs without annotations, learn about state-of-the-art techniques used by lgtm.com, and understand how static analysis can benefit your development process. Gain insights into the methods employed to detect issues in popular libraries like requests and numpy. Delve into topics such as abstract syntax, control flow graphs, and call contexts. Suitable for all Python developers, especially those familiar with tools like pyflakes, pep8, pylint, or mypy. Learn how to leverage static analysis to produce better code and enhance your software development skills.
Syllabus
Intro
Curiosity Lander
What is code analysis
What makes for good code analysis
Can we do this for Python
LGTM
Example query
Accuracy
Abstract Syntax
Checking for errors
Control flow graph
Split control flow graph
Pruning
Call context
LGTM Django
LGTM Query
Recap
Open Space
Questions
False positives
Taught by
EuroPython Conference