liveBook · Manning

Bug

As explained in "Looks Good to Me"

An error or flaw in software that can cause incorrect, unsafe, or undesirable behavior.

A bug is an error or defect that produces incorrect behavior or allows defect-prone code into released software. Code reviews can expose errors the original developer missed, but their bug-finding role remains debated. section 1.3.1 section 3.1.1

Treat bug detection as one part of a broader quality strategy:

  • Use unit tests and developer checks to catch expected failures before review. section 3.1.1
  • Use review to catch subtle functionality errors that tests or the original author missed. section 3.1.1
  • Pair reviews with CI/CD and readable, maintainable code to reduce defects reaching production. section 1.3.1

The wrong cache

A pull request retrieves data from a cache and includes passing unit tests, but the implementation reads from the wrong cache. Review reveals the subtle functionality defect. section 3.1.1

How "Looks Good to Me" covers it

How deep it goes
Distinguishes obvious, subtle, hidden, low-level, and functionality defects but stops short of a general debugging procedure.
Examples
Uses a passing-test pull request that retrieves data from the wrong cache as a subtle functionality-defect example.
What it assumes
Assumes familiarity with software changes, pull requests, unit tests, code review, and deployment.
What you can do after
Diagnose bugs with code review by looking for functionality errors that unit tests and the original author missed.
How it connects
Connects bugs with code review, CI/CD, unit tests, pair programming, mob programming, security bugs, and maintainability.

Also explained in

Compare how 3 books explain bug →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of "Looks Good to Me". The section links point to the parts of the book it draws on.