At a glance
- Identifier: #955
- Stage: RFC 3 / Accepted
- Champion: @benjaminjkraft
- Latest activity: Spec PR merged on 2025-06-26
- Spec PR: https://github.com/graphql/graphql-spec/pull/955
- Related:
Spec PR description
Right now the spec says that, for example, if the schema does not define a mutation root type, then the schema does not support mutations. But there's no validation rule for it, which means that many parsers (including graphql-js) treat a mutation as valid against such a schema. (Indeed, many end up considering any mutation as valid, since they don't know what type to validate the root selection set against.) This commit adds a validation rule to make the schema text explicit.
Slated for discussion at the June 2 2022 working group meeting. Replaces #947. See also graphql/graphql-js#3592.
Update October 2024: this PR has been refreshed including changes proposed in #1098 and Benjie's editorial edits.
Fixes #1097
Timeline
June 2025
- Spec PR merged on 2025-06-26 by leebyron
- Advanced to RFC 3 on 2025-06-26 by leebyron
- Added to WG agenda on 2025-06-26
December 2024
- Advanced to RFC 2 on 2024-12-05 by leebyron
- Added to WG agenda on 2024-12-05
- Mentioned in WG notes on 2024-12-01
October 2024
- Top comment edited on 2024-10-17 by benjie
- 9 commits pushed on 2024-10-17
- @benjie committed "Undo changes to Section 3"
- @benjie committed "Merge branch 'main' into operation-type-validation"
- @benjie committed "Editorial"
- @benjie committed "Merge remote-tracking branch 'Shane32/Shane32-patch-1' into operation…"
- @benjie committed "Move Shane's content"
- @benjie committed "More editorial"
- @benjie committed "More editorial"
- @benjie committed "Update spec/Section 5 -- Validation.md"
- @benjie committed "Update spec/Section 5 -- Validation.md"
- 2 commits pushed on 2024-10-04
- @Shane32 committed "Merge branch 'main' into Shane32-patch-1"
- @Shane32 committed "Reformat"
June 2024
- @Shane32 committed "Apply suggestions from code review" on 2024-06-04
May 2024
- 4 commits pushed on 2024-05-27
- @Shane32 committed "Add 5.2.4 Operation Type Configuration"
- @Shane32 committed "Update spec/Section 5 -- Validation.md"
- @Shane32 committed "Update spec/Section 5 -- Validation.md"
- @Shane32 committed "Update spec/Section 5 -- Validation.md"
June 2022
- 2 commits pushed on 2022-06-13
- @benjaminjkraft committed "typofix"
- @benjaminjkraft committed "indentation"
- Advanced to RFC 1 on 2022-06-02 by leebyron
- Added to WG agenda on 2022-06-02
- Spec PR created on 2022-06-01 by benjaminjkraft
- Top comment edited on 2022-06-01 by benjaminjkraft
- 2 commits pushed on 2022-06-01
- @benjaminjkraft committed "Add validation rule that operation types exist"
- @benjaminjkraft committed "prettier"