-
Notifications
You must be signed in to change notification settings - Fork 1.1k
RFC: OneOf Input Objects #825
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
Open
benjie
wants to merge
53
commits into
graphql:main
Choose a base branch
from
benjie:oneof-v2
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+189
−2
Open
Changes from 4 commits
Commits
Show all changes
53 commits
Select commit
Hold shift + click to select a range
c385058
Renumber list items
benjie f6bd659
@oneOf input objects
benjie 39e593c
@oneOf fields
benjie b6741c3
Fix typos (thanks @eapache!)
benjie d17d5ec
Much stricter validation for oneof literals (with examples)
benjie dca3826
Add missing coercion rule
benjie 7e02f5a
Clearer wording of oneof coercion rule
benjie 4111476
Add more examples for clarity
benjie 6754e0a
Rename introspection fields to oneOf
benjie 7c4c1a2
Oneof's now require exactly one field/argument, and non-nullable vari…
benjie bb225f7
Remove extraneous newline
benjie 05fde06
graphgl -> graphql
benjie e8f6145
Apply suggestions from @eapache's review
benjie 08abf49
Apply suggestions from code review
benjie 59cb12d
Update spec/Section 3 -- Type System.md
benjie c470afb
Merge branch 'main' into oneof-v2
benjie 99aa5d9
Remove Oneof Fields from spec
benjie 691087d
Oneof -> OneOf
benjie 7109dbc
Spellings
benjie 05ab541
Remove out of date example
benjie 6a6be52
Rename __Type.oneOf to __Type.isOneOf
benjie de87d2f
Add a:null example
benjie 57e2388
Rewrite to avoid ambiguity of language
benjie 5a966f2
Forbid 'extend input' from introducing the @oneOf directive
benjie e78d2b5
Merge branch 'main' into oneof-v2
benjie c6cd857
Merge branch 'main' into oneof-v2
benjie d106233
Add yet more examples to the example coercion table
benjie 87d0b22
Indicate `@oneOf` is a built-in directive
benjie d88d62a
Update spec/Section 3 -- Type System.md
benjie a810aef
Merge branch 'main' into oneof-v2
benjie a1563a9
remove OneOf-specific rule in favor of update to VariablesInAllowedPo…
yaacovCR b45c0e4
Clarify IsNonNullPosition algorithm
benjie 0c9830e
Clarify OneOf examples
benjie c4d0b50
Add more examples
benjie 340594e
Remove new validation rule in favour of updates to existing rules
benjie dbccf84
Null literal is separate
benjie 17f1304
Merge branch 'main' into oneof-v2
benjie d15f7bb
Merge branch 'main' into oneof-v2
benjie 6310475
Use 'execution error' and 'raise' rather than throw an error
benjie c26463f
Update spec/Section 3 -- Type System.md
benjie ff986be
Whitespace
benjie 016f47f
Clarify algorithm
benjie b1ff1ab
Rename 'Tagged'
benjie 9bec236
editorial: define and link _OneOf Input Object_
leebyron 59ad4b7
Merge branch 'main' into oneof-v2
leebyron dddd4b8
Merge branch 'main' into oneof-v2
benjie 0f19c3e
execution error -> request error (input coercion)
benjie 128807c
Simplify and clarify OneOf Input Object additional coercion rules
benjie d3e359b
Clarity and correctness
benjie ec85436
Simplify
benjie 47cbe95
Use a colon
benjie 2998f7d
Use the correct error for the situation
benjie 5f6e777
Remove example which will not always fail until #1059 is adopted
benjie File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This feels kinda awkward, like we're skirting around the idea of having fundamentally different types of fields without really committing to it?