-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Misconfigured Flags Should Error #68
Comments
A potential solution is to allow customization of the behavior when a flag is not found. By default, the flag is considered false, but a user can change the default to true or throw. |
I agree, this seems like a better solution. |
I believe we should add a new error type to If the behavior is on by default then it is a breaking change so it would need to be done in a major version bump. |
@jimmyca15 I have a draft PR here for this change, interested in any feedback before I continue on this approach. |
Any chance this can be bumped / moved forward? Looks there was a PR with comments and it is now stale with conflicts? |
Enabled in release 2.4.0 |
I think that if a flag is used and that flag is not configured then the app should error and not just default the flag to false.
For example, if a configured flag is for some reason omitted in a production config (or mis-spelled) then the app will continue to run without error and the fault may not be noticed.
If a flag is being used programmability then this could cause data issues.
If a flag is being used to control UI elements such as some legal wording that needs to be shown, then by defaulting to false the company could be in breach of laws.
The text was updated successfully, but these errors were encountered: