When is a feature flag actually safe to remove?
by•
Getting a release flag to 100% is easy to call "done". But an older client may still evaluate it, and the old branch stays in the code until somebody removes it.
I’d put an owner and a removal condition in the PR that adds a temporary flag. Before taking it out, I’d check recent evaluations across environments and supported client versions, then search the codebase for references. An operational kill switch is a different decision; that one may need to stay.
What tells you a release flag is safe to remove, and who owns the cleanup after rollout?
13 views
Replies
On mobile the honest answer is: when the oldest build people still run stops reading it, and that date is set by your users, not by you. Plenty of people keep an old version for months. So my rule is that the backend never assumes a new client, anything new on the server is optional and an old build just ignores it, and a release flag only goes once the minimum supported version is past the build that needed it. Your split with the kill switch matters a lot. I would make it visible in the name, release_ vs ops_, so nobody deletes the wrong kind during a cleanup.