Ben Everard’s code always looks like a crime scene.
Author Adam Tornhill Publisher Pragmatic Bookshelf Price £23.99 ISBN 978-1680500387
It doesn’t matter how good your code Is, there are bugs In it, and one of the challenges of programmers is finding where they’re hiding. In Your Code as a Crime Scene, Adam Tornhill Introduces the Idea of using forensic techniques to work out where they’re most likely to be. The process is based on geographic offender profiling, which attempts to locate the likely location of a criminal based on the pattern of their crimes. Tornhill uses tools and techniques that attempt to locate likely places for bugs based on the location of complexity In and changes to the code base. This spatial mapping produces visualisations that highlight a series of ‘hotspots’ where bugs are likely to occur.
By Identifying these hotspots, you can focus your bug squashing activities in the most fruitful places, and also use this knowledge to inform your development practices (should this code be re-factored?) and human resources (should more people know how this code works?). In small projects, developers can easily keep track of the whole codebase, and so Identifying hotspots Isn’t very useful, but as projects get larger, it becomes more useful to know where problems may arise. Adam Tornhill takes the reader through a series of real open source projects to demonstrate the techniques. This isn’t a failsafe approach guaranteed to leave your software spotless, but could be a useful weapon in the endless battle for software quality.
A novel approach to software analysis that could prove useful for managing large projects.