I shipped a transaction bug, so I built a linter
Summary
Léon h explains shipping a transaction bug that leaked operations outside its boundary, and how they built a custom linter to catch such issues at compile time. The article describes the problem, the Go analysis framework, and a deep dive into the implementation (AST walking, identifying transaction calls, tracking the transaction parameter, traversing callbacks, and recursive analysis of helpers), plus testing with analysistest and CI integration. It serves as a practical blueprint for developers to build internal static-analysis tools to improve reliability and prevent subtle data integrity bugs.