Before finishing any task (5–15 min max)
- Add a comment explaining a non-obvious decision or “why”
- Clarify or improve an error message
- Extract a magic number into a named constant
- Add type hints to function signatures
- Add a log statement that would speed up future debugging
- Fix a flaky test if you spot one
- Update the
READMEwith something that confused you - Extract repeated logic into a shared/reusable module
- Add examples or error cases to API/function docs
- Document a deployment or config gotcha
The 5 questions to ask yourself
- What confused me while working on this?
- What will confuse the next person?
- What was non-obvious or surprising?
- What would make debugging this easier?
- What pattern am I repeating that could be extracted?
The Rule
- 5 min minimum, 15 min maximum.
- If it needs more, create a ticket—don’t skip it entirely.
Follow me
Thanks for reading this article. Make sure to follow me on X, subscribe to my Substack publication and bookmark my blog to read more in the future.
Photo by Pixabay.