Abstractions and Regrets

Every Abstraction I Regret

The best code I ever deleted was a utility function called format_response. It accepted a response object, a format string, a fallback value, an optional transformer function, and a boolean for whether to strip whitespace. It was used in exactly one place. I wrote it because I thought I’d need it again. I didn’t. It sat in utils.py for eight months, collecting type: ignore comments and confusing every developer who opened the file. ...

February 20, 2026 · 7 min · Muhammad Hassan Raza