Tech Lead Journal

#241 - Your Code as a Crime Scene: The Psychology Behind Software Quality - Adam Tornhill


Listen Later

(04:00) Brought to you by Unleash

Unleash is a private, flexible, and scalable feature flag system that lets teams decouple deployments from releases. It reduces the risk of shipping new features and gives organizations real-time control over what reaches production. And as AI accelerates development, Unleash helps engineering teams move fast and stay stable with safe rollouts and instant kill switches. Start a free trial of Unleash at ⁠getunleash.io/pricing⁠.


Why do so many software projects still fail despite modern tools? The answer often lies in the psychology of the team, not the technology stack.

Software development is often viewed purely as a technical challenge, yet many projects fail due to human factors and cognitive bottlenecks. In this episode, Adam Tornhill, CTO and Founder of CodeScene, shares his unique journey combining software engineering with psychology to solve these persistent industry problems. He explains the concept of “Your Code as a Crime Scene,” a method for using behavioral analysis to identify high-risk areas in a codebase that static analysis tools often miss.

Adam covers the tangible business impact of code health, specifically how it drives predictability and development speed. He explains why 1-2% of our codebase accounts for up to 70% of our development work, and how focusing on these hotspots can make our team 2x faster and 10x more predictable. Adam also provides a critical reality check on the rise of AI in coding, exploring whether it will help reduce technical debt or accelerate it, and offers strategies for maintaining quality in an AI-assisted future.

Key topics discussed:

  • Combining psychology and software engineering
  • Why predictability matters more than speed
  • Treating your codebase as a crime scene
  • Behavioral analysis vs. static analysis
  • The hidden danger of the “Bus Factor”
  • Will AI help or hurt code quality?
  • Why healthy code helps both humans and AI
  • Essential guardrails for AI-generated code

Timestamps:

  • (00:00) Trailer & Intro
  • (01:29) Career Turning Point: From Developer to Psychologist
  • (02:36) Combining Psychology and Software Engineering
  • (04:00) Why Engineering Leaders Need Psychology Knowledge
  • (05:46) The Root Cause of Failing Software Projects
  • (07:43) Why Code Abstractness Makes Quality Hard to Measure
  • (09:29) Aligning Code Quality with Business Outcomes
  • (11:37) Code Health: 2x Speed, 10x Predictability
  • (12:58) Why Predictability is Undervalued in Software
  • (19:53) Introducing “Your Code as a Crime Scene”
  • (21:57) Behavioral Code Analysis: Hotspot Analysis vs Static Code Analysis
  • (24:06) Behavioral Code Analysis: Understanding Change Coupling
  • (26:30) Dealing with God Classes
  • (29:40) Behavioral Code Analysis: The Social Side of Code
  • (31:33) Why Developers Aren’t Interchangeable
  • (33:14) Introduction to CodeScene
  • (36:48) Will AI Help or Hurt Code Quality?
  • (39:14) Essential Guardrails for AI-Generated Code
  • (42:06) Using CodeScene to Maintain Quality in the AI Era
  • (43:06) How AI Accelerates Technical Debt at Scale
  • (45:54) Why AI-Friendly Code is Human-Friendly Code
  • (48:32) Documentation: Capturing the “Why” for Humans and AI
  • (50:42) The Reality Check: Future of Software Development with AI
  • (52:41) 3 Tech Lead Wisdom

_____

Adam Tornhill’s Bio
Adam Tornhill is the founder and CTO of CodeScene and the best-selling author of Your Code as a Crime Scene. Combining degrees in engineering and psychology, Adam helps companies optimize software quality using AI-driven methodologies. He is an international keynote speaker and researcher who enjoys retro computing and martial arts in his spare time.

Follow Adam:

  • LinkedIn – linkedin.com/in/adam-tornhill-71759b48
  • CodeScene – codescene.com
  •  Your Code as a Crime Scene – pragprog.com/titles/atcrime2/your-code-as-a-crime-scene-second-edition


Like this episode?
Show notes & transcript: techleadjournal.dev/episodes/241.
Follow @techleadjournal on LinkedIn, Twitter, and Instagram.
Buy me a coffee or become a patron.

...more
View all episodesView all episodes
Download on the App Store

Tech Lead JournalBy Henry Suryawirawan

  • 4.7
  • 4.7
  • 4.7
  • 4.7
  • 4.7

4.7

13 ratings


More shows like Tech Lead Journal

View all
Software Engineering Radio by se-radio@computer.org

Software Engineering Radio

271 Listeners

Hanselminutes with Scott Hanselman by Scott Hanselman

Hanselminutes with Scott Hanselman

383 Listeners

The Changelog: Software Development, Open Source by Changelog Media

The Changelog: Software Development, Open Source

289 Listeners

Software Engineering Daily by Software Engineering Daily

Software Engineering Daily

624 Listeners

Talk Python To Me by Michael Kennedy

Talk Python To Me

584 Listeners

Soft Skills Engineering by Jamison Dance and Dave Smith

Soft Skills Engineering

288 Listeners

Thoughtworks Technology Podcast by Thoughtworks

Thoughtworks Technology Podcast

43 Listeners

Super Data Science: ML & AI Podcast with Jon Krohn by Jon Krohn

Super Data Science: ML & AI Podcast with Jon Krohn

303 Listeners

Y Combinator Startup Podcast by Y Combinator

Y Combinator Startup Podcast

226 Listeners

Syntax - Tasty Web Development Treats by Wes Bos & Scott Tolinski - Full Stack JavaScript Web Developers

Syntax - Tasty Web Development Treats

985 Listeners

CoRecursive: Coding Stories by Adam Gordon Bell - Software Developer

CoRecursive: Coding Stories

189 Listeners

Practical AI by Practical AI LLC

Practical AI

209 Listeners

AWS Podcast by Amazon Web Services

AWS Podcast

203 Listeners

The Stack Overflow Podcast by The Stack Overflow Podcast

The Stack Overflow Podcast

63 Listeners

This Day in AI Podcast by Michael Sharkey, Chris Sharkey

This Day in AI Podcast

210 Listeners