Writing
Mostly things that broke, and what I changed afterwards. I write them up because the mistake is usually more transferable than the fix.
The permission check that did two jobs
One flag guarded both "can see every client" and "can create logins". Splitting it into two questions took an afternoon. Noticing it took a year.
My DMARC check passed domains that had no protection at all
Looking for the record is not the same as reading it. A substring match gave a green tick to `+all` and to `p=none`, which are the two ways of having the record and none of the benefit.
258MB of JSON, and the query parameter that fixed it
An endpoint that worked fine in testing started returning 502s in production. The response was a quarter of a gigabyte, and most of it was photographs.
Every script I write backs up what it touches
The rule came from breaking a working config with no way back. It costs three lines and it has saved me more times than I would like to admit in public.