Skip to content
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

Option to add future-proof "redundant" Other(value) in enum? #89

Closed
jfrolich opened this issue Feb 26, 2020 · 1 comment
Closed

Option to add future-proof "redundant" Other(value) in enum? #89

jfrolich opened this issue Feb 26, 2020 · 1 comment

Comments

@jfrolich
Copy link
Collaborator

See: mhallin/graphql_ppx#69

GraphQL considers adding an enum to be a non-breaking change, because most type systems it seems aren't sound and so the developer always has to include a catch-all. In this world, adding a value to an enum means the old application should (mostly?) keep working, even when it encounters a value it doesn't understand.

Right now, we can't really do that for clients with graphql_ppx. It might be nice to have some option (or even required) to have a catch-all `Other(stringValue) to make apps much safer in the face of GraphQL's "non-breaking" [😄] changes.

@jfrolich jfrolich added this to the 1.0.0 milestone Feb 26, 2020
@baransu
Copy link
Collaborator

baransu commented Feb 26, 2020

Duplication of #5

@baransu baransu closed this as completed Feb 26, 2020
@jfrolich jfrolich removed this from the 1.0.0 milestone Feb 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants