liveBook · Manning

Precheck

As explained in "Looks Good to Me"

An automated validation performed before or when a code change is submitted for review.

A precheck is an automated validation that runs before or when a pull request is submitted. It catches routine problems early, keeping review focused on issues that require human judgment. section 4.4.4 section 5.2.2

Use a precheck for issues that are obvious, repeatable, and inexpensive to fix:

  • Flag abandoned TODOs, unused variables, commented-out code, debugging statements, and other forgotten code. section 4.4.4
  • Run spelling, grammar, lint, style-consistency, language-convention, and in-house-standard checks. section 4.4.4
  • Check comments for omissions, inaccuracies, unnecessary content, and copied blocks whose wording was not updated. section 4.4.4

A prepared pull request

A developer opens a pull request containing a console.log(), an abandoned TODO, and a lint violation. The precheck fails, so the pull request is not considered properly prepared until those issues are fixed. section 4.4.4

Choose review tooling that can trigger checks when a pull request opens, connect bots, or run custom tasks and scripts. Automation supports preparation but does not replace decisions about which problems belong in review. section 5.2.2 section 4.4.4

How "Looks Good to Me" covers it

How deep it goes
Defines candidates and failure expectations, but stops short of prescribing a specific implementation.
Examples
Uses TODOs, spelling, grammar, forgotten code, comments, lint, style consistency, and language conventions as check targets.
What it assumes
Assumes team standards and language or framework conventions, while identifying routine checks that should be automated.
What you can do after
Operate configurable pull-request checks that remove routine defects before reviewers spend time on the change.
How it connects
Connects code review with linting, coding standards, bots, scripts, and pull-request tooling.

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.