Skip to content

Stale README Spotter

Run the Stale README Spotter MicroSim Fullscreen

About This MicroSim

A README is right on the day it is written. Then the code moves and the README stays put. This MicroSim shows eight lines from the README of the dating-safety app used as the running example, next to a panel of facts read from the code: the ports in the configs, the variables the env schema requires, the scripts in package.json, and so on.

Your job is to check each line instead of trusting it. A line is stale when anything in it disagrees with the code, or when it leaves out something the code says is required. A line matches the code when everything in it agrees. One line is stale even though every word in it is true. Port numbers, variable names and the wording of each line are illustrative.

How to Use

  1. Press Open code facts to see what the code says.
  2. Click a README line to select it, then press Matches the code or Stale. The next unmarked line is selected for you.
  3. You can change any mark until you press Check.
  4. When all eight lines are marked, press Check. Each line shows ✓ or ✗.
  5. Click any line to read why, and which code fact it was checked against.
  6. Press Start over to clear your marks.

Iframe Embed Code

You can add this MicroSim to any web page by adding this to your HTML:

<iframe src="https://arunbatchu.github.io/good-enough-engineering/sims/stale-readme-spotter/main.html"
        height="700px"
        width="100%"
        scrolling="no"></iframe>

Lesson Plan

Grade Level

Adult professional (Good Enough Engineering)

Duration

10-15 minutes

Learning Objective

The learner will differentiate stale lines from true lines in a README by checking each line against facts read from the code, flagging all stale lines with no more than one wrong flag.

Prerequisites

  • README
  • Architecture doc
  • Stale documentation
  • .env.example
  • Docs generated from code

Activities

  1. Check (5 min): Mark all eight lines against the code facts and press Check.
  2. Review (5 min): Find the line that is stale without saying anything false. Say what it leaves out.
  3. Apply (5 min): Open your own README. List every port, variable and command it names, and check each one against the code.

Assessment

Mastery is all five stale lines flagged with no more than one true line flagged as stale. Opening the code facts panel is exploration, not evidence.

References

  1. Chapter 15: Technical Debt — the chapter this MicroSim belongs to.
  2. Martin Fowler, Refactoring: Improving the Design of Existing Code (Addison-Wesley, 1999).