At a glance
- Project
- GraphQL Spec
- Identifier
- #1177
- Stage
- RFC 1 / Proposal
- Champion
- @benjie
- Updated
- 2025-07-04
- Latest activity
- 4 commits pushed on
- Source
- Pull request
Pull request description
GraphQL.js uses a getFieldDef() helper:
called from executeField() to get the field definition to execute; returning meta-field definitions as appropriate.
This spec change reflects this existing behavior as best we can.
(Technically GraphQL.js' executeField() function overlaps responsibilities between the ExecuteField() and ExecuteCollectedFields() algorithms in the spec - specifically, executeField() may return undefined, resulting in executeFields() not adding the entry to the result object, whereas this conditional addition is handled in ExecuteCollectedFields() in the spec and we cannot/should not differentiate between null and undefined in this way.)
Timeline
July 2025
- 4 commits pushed on
- @benjie committed "Introduce ResolveMetaFieldValue algorithm"
- @benjie committed "Refactor to add assertion"
- @benjie committed "This should require less refactoring when we add future meta-fields"
- @benjie committed "Could be an introspection type"
- Pull request created on by benjie
- @benjie committed "Incorporate meta-fields into ExecuteCollectedFields" on
- Advanced to RFC 1 on by leebyron
- Discussed in GraphQL WG
The GraphQL Working Group meeting focused on reviewing recent specification updates and editorial changes, including discussions about request errors, operation execution, and meta fields implementation. The team evaluated various RFC proposals related to coercion algorithms, schema coordinates, and the handling of meta fields in GraphQL.js, with several members providing feedback on potential improvements and clarifications. The conversation ended with discussions about the implementation of experimental features like executeIncrementally and the handling of asynchronous iterators, with the team agreeing to maintain a general specification while allowing for implementation-specific details in GraphQL.js.
Zoom summary · GraphQL WG · 2025-07-03Lee: Review and finalize editorial changes for schema coordinates Meta field handling in the spec
Zoom summary · GraphQL WG · 2025-07-03Benjie: Create a more detailed proposal for execute Meta field algorithm with specific handling for __type, __schema, and __type Meta fields
Zoom summary · GraphQL WG · 2025-07-03Rob: Create a PR to update GraphQL.js regarding schema coordinate Meta field behavior
Zoom summary · GraphQL WG · 2025-07-03The GraphQL Working Group meeting began with Lee noting the thinner attendance due to the holiday week and introduced the agenda, which included updates on the spec, editorial changes, and several RFCs. Benjie highlighted the upcoming discount period for GraphQL Conference tickets and provided a summary of the previous meeting's progress, including merged items like executable descriptions and deprecation discussions. The group planned to discuss schema coordinates, argument values, list coercion algorithms, and incorporating Meta fields into execute collected fields, among other topics. Lee encouraged attendees to review the previous meeting's outcomes and emphasized the importance of highlighting upcoming dates to avoid scheduling conflicts.
Zoom summary · GraphQL WG · 2025-07-03GraphQL Meta Fields Implementation DiscussionThe team discussed the specification of meta fields and their implementation in GraphQL.js. They agreed that meta field resolution should be left implementation-specific, with GraphQL.js currently returning virtual objects. Mark will update the JavaScript version to ensure it aligns with this approach. The team decided not to rush the specification cutoff date of July 1st, as most major changes have been merged and they are close to RFC 3. Leebyron will conduct a final editorial review, and Mark will submit a pull request to address the remaining issues.
Zoom summary · GraphQL WG · 2025-07-03Leebyron and Benjie discussed recent changes to the GraphQL specification, focusing on clarifying the collection and execution phases. They highlighted a significant renaming and cleanup of variables, which Benjie had worked on, and encouraged others to review this change, especially those working on implementations like GraphQL.js or GraphQL Kotlin. Benjie also explained that he had added support for executing Meta fields in the specification, aligning it with the behavior in GraphQL.js, and avoided using undefined or null values to maintain consistency. Leebyron approved of these changes and suggested that the next steps involve further work on top of this updated foundation.
Zoom summary · GraphQL WG · 2025-07-03GraphQL Meta Fields Implementation DiscussionThe team discussed the placement and implementation of meta fields in the GraphQL specification. Leebyron and Benjie agreed that the current location in the spec is appropriate, as it correctly implements the behavior for meta fields. They decided that this change should move through the RFC phases quickly since it addresses a clear hole in the specification. The team also discussed the implications of meta fields returning complex types instead of simple strings, but ultimately decided to keep the implementation implicit rather than making it more explicit, as they felt it would unnecessarily complicate the spec. Leebyron concluded that this change should at least be RFC 1, as it clearly solves a problem in the specification.
Zoom summary · GraphQL WG · 2025-07-03GraphQL Meta Fields DiscussionLee and Benjie discuss two potential approaches for defining meta fields in the GraphQL specification. They agree to leave the current proposal as RFC1 and consider a more detailed alternative that defines the three meta fields and their behavior. Lee suggests that once they decide on the appropriate draft, it can likely move directly to RFC3 without needing GraphQL.js changes. Benjie notes that the implementation needs to be in the "execute collected fields" section. They also discuss where to place the new algorithm in the spec, with Lee preferring to keep it in the execution section.
Zoom summary · GraphQL WG · 2025-07-03