npm / graphql
graphql
What changed in graphql 14 to 17, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.
86 breaking15 deprecations29 new APIs and options2 performance12 behavior and defaults1 tooling49 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initgraphql 1730 changes
Breaking changes 1
Renames maxTokens to maxLexicalTokens; update parser option usage accordingly.
New APIs and options 5
Adds a parser option to limit comments.
Adds a parser option to limit source length.
Adds a way to limit the complexity of overlapping field validation.
Adds configuration for list type nesting in the parser; the maxListDepth change was reverted.
Adds configuration for printer indentation depth.
Behavior and default changes 2
GraphQL now allows empty selection sets.
Directives on directive definitions are graduated, allowing them to be used without experimental status.
Fixes and other changes 22
Skips suggestions for disabled arguments.
Passes parser options through buildSchema.
Keeps collected fields separate by parent type during validation.
Field collection skips deferred fragments only when the same directive is used.
Handles fragment cycles during defer/stream directive validation on root fields.
References ESM source maps from every emitted module and identifies ESM modules in source map metadata.
Keeps argument defaults inside fragments during validation.
Prevents error completions for fragments that were not announced.
Prevents successful shared results from being lost or delayed.
Bounds shared fragment traversal during introspection validation.
Aligns source locations at chunk boundaries and keeps EOF carets after the final character.
Avoids inherited variable getters when reading nested literal values.
Requires matching variable definitions when checking whether fields overlap.
Initializes variables used in subscription validation.
Allows fragments with variables to appear before operations.
Default-value changes on input object fields are now detected.
Fixes the context for the schema argument mapper.
Emits asyncStart after promise settlement to match native tracePromise behavior.
Directives are applied when SDL contains both type definitions and extensions with directives.
Invalid fragment variables now raise a request error.
Directive locations for input field arguments in extensions are corrected.
OneOf inhabitability is addressed.
graphql 1690 changes
Breaking changes 48
Sibling errors are no longer added after propagation, changing how errors are reported.
The Array.from polyfill has been dropped.
Non-iteratable ArrayLike objects are no longer supported.
The printer no longer adds indentation inside block strings.
Support for long-deprecated comments as descriptions has been dropped.
Default exports were replaced with named exports.
Deprecated rule aliases have been removed; use the non-deprecated rule names.
The strings true, false, and null are disallowed as enum values.
Error extension types now use named interfaces instead of an anonymous Record.
Schema type extensions are no longer optional.
The find polyfill has been removed.
The previously deprecated function has been removed.
Name validation now occurs in GraphQL constructors.
The execute and subscribe functions no longer accept positional arguments.
The template argument was dropped from GraphQLFormattedError.
The previously deprecated method has been removed.
An interfaces thunk may no longer return null or undefined.
The deprecated isDeprecated properties on GraphQLEnumValue and GraphQLField have been removed.
The isFinite polyfill has been removed.
The isInteger polyfill has been removed.
isNode checks the exact value of a node's kind.
The parser no longer supports legacy syntax.
The Node custom inspect function has been removed.
Support for Node 10 was dropped.
Support for Node v15 was dropped.
The Object.entries polyfill has been removed.
The Object.values polyfill has been removed.
Support for older browsers has been dropped.
OperationTypeNode is now an enum.
Printed schema output no longer has a trailing newline.
Schema types now use ReadonlyArrays.
resolveType no longer supports returning a GraphQLObjectType.
A serialize function may no longer return null.
Use specifiedBy instead of specifiedByUrl.
introspectionFromSchema enables specifiedByUrl by default.
subscribe no longer maps errors from AsyncIterable values.
A subscription field cannot be an introspection field.
Symbol polyfills have been removed.
Thunk types were split into ThunkArray and ThunkObjMap.
Thunks are restricted to support only ObjMap and Array.
Support for TypeScript versions before 3.7 was dropped.
Support for TypeScript 3.7 was dropped.
TypeScript uses unknown for Flow's mixed type.
Validation now limits the maximum number of errors to 100 by default.
visit no longer accepts template arguments for possible nodes.
visitInParallel is faster by dropping support for unknown nodes.
The fourth form of visitor has been removed.
The visitor function no longer accepts the visitorKeys argument.
Deprecations 11
A deprecated note was added to assertValidExecutionArguments.
ASTKindToNode is deprecated.
ExecutionArgs was broadened.
formatError is deprecated; GraphQLError.toJSON was added instead.
Fragments with variables are deprecated, and naming was changed to reflect that.
getOperationRootType is deprecated in favor of GraphQLSchema.getRootType.
graphql/subscriptions is deprecated; its code has moved to execution.
GraphQLError.toJSON was added as the replacement for deprecated formatError.
The printError function is deprecated.
SubscriptionArgs is deprecated and ExecutionArgs was broadened.
The getFieldDefFn argument is deprecated and has been moved to the last position.
New APIs and options 12
Backports the maxLexicalTokens parser option to v16.
Adds experimental support for directives on directive definitions.
Allows configuring the introspection depth for ofType references.
Adds support for schema coordinates.
The introspection field __Directive.args now has the includeDeprecated argument.
TResult was added to the GraphQLFieldResolver signature.
Type parameters were added to GraphQLScalar.
GraphQLSchema.getRootType was added.
OperationTypeNode is exported as a value.
Symbol.toStringTag was added to every publicly exported class.
TypeKind is exported as a value.
A validation rule for unique argument definition names was added.
Behavior and default changes 6
Implements changes for executable descriptions, allowing developers to use descriptions with executable definitions.
Error.toStringTag now returns GraphQLError instead of Object.
The lexer supports full Unicode.
getNamedType was refined for input and output types.
GraphQLList is now a proper class.
GraphQLNonNull is now a proper class.
Fixes and other changes 13
Backports changes to OverlappingFieldsCanMerge in v16.
Fixes variable own-property checks when converting values from an AST.
Uses Object.create(null) instead of {} to avoid prototype issues.
This is the first 16.x.x release with trusted publishing and provenance, which developers can consider when evaluating package authenticity.
Fixes incorrect validation errors when variable descriptions are used.
Catches unhandled exceptions in abstract resolution.
Removes oneof validation from values of the correct type.
Parsing and AST representation were refined to represent ConstValue.
Introspection now supports deprecated input values.
extensionASTNodes is always populated with an empty array when there are no extension nodes.
GraphQLError.extensions is always present.
deprecationReason is preserved on GraphQLInputField instances.
visitorKeys was brought back.
graphql 1542 changes
Breaking changes 26
AST node types are now exact objects.
Non-finite numbers are now rejected.
The deprecated coerceValue function was removed.
Enum parsing and serialization methods now throw on invalid values.
The TypeScript-specific TData type parameter was removed.
toConfig now always returns extensionASTNodes as an array.
Non-standard properties were removed from field objects.
graphql no longer has a runtime dependency on iterall.
description is now undefined by default.
Default values were removed for required fields in GraphQL*Config types.
Custom enum values can no longer be undefined.
Scalar errors are converted from TypeError to GraphQLError.
The deprecated allowedLegacyNames property was removed.
The deprecated introspectionQuery constant was removed.
isSpecified* and isIntrospectionType now accept only correct types.
The deprecated isValidJSValue function was removed.
The deprecated isValidLiteralValue function was removed.
The node argument was removed.
Lexer is now a proper class; createLexer and passthrough options were removed.
Support for Node 6 and Node 8 was dropped.
Providing an empty string as operationName now produces an error.
Built-in scalars’ parseLiteral methods now throw TypeError.
The schema now always validates basic config structure.
The TypeScript-specific TArgs type parameter was removed.
The Rule suffix was added to all validation rule names.
The deprecated getErrors method was removed.
New APIs and options 5
Adds the maxComments parser option in v15.
Adds the maxLexicalTokens parser option in v15.
Schemas can define interfaces that implement other interfaces.
Introspection now supports repeatable directives.
A description can now be added to a schema.
Behavior and default changes 2
buildSchema and extendSchema now support schema extensions.
Serialization for Int, Float and Boolean now works with objects.
Tooling 1
Breaking-change detection now checks for removing repeatable from a directive.
Fixes and other changes 8
Backports changes to overlapping-fields validation in v15.
An empty string is now a valid deprecationReason.
Introspection now exposes fields and values with an empty deprecationReason.
Schema printing now supports empty descriptions and does not break description lines.
NaN values are now checked inside scalar serialize methods.
Missing validation rule exports were added, including legacy names for rules missing in versions before 14.6.0.
Null variables are now coerced correctly for non-nullable types.
Fixed variable values of non-null type with a default value.
graphql 1432 changes
Breaking changes 11
The “Schema Change” keys used to detect added arguments and input fields change names.
The “Schema Change” keys used to detect added arguments and input fields change names.
The API changes how error message extensions are formatted; wrapping graphql's formatError preserves existing server responses.
GraphQL*Config types are now exact types.
Node v4 and v9 are no longer supported; Node v10 is supported.
The deprecated Introspection field onField is removed.
The deprecated Introspection field onFragment is removed.
The deprecated Introspection field onOperation is removed.
ProvidedNonNullArguments is renamed to ProvidedRequiredArguments.
Invalid scalar value coercion is rejected, with stricter coercion of scalar types.
The VariablesDefaultValueAllowed validation rule is removed.
Deprecations 4
getDescription is deprecated; use the schema AST node to get descriptions.
introspectionQuery is deprecated; use getIntrospectionQuery.
isValidJSValue is deprecated; use coerceValue.
isValidLiteralValue is deprecated; use validation.
New APIs and options 7
Directives can be added to variable definitions behind the experimentalVariableDefinitionDirectives flag.
getOperationRootType(schema, operationAST) is exposed.
AST node predicate is added.
Predicate is added to test whether an argument is required.
Predicate is added to test whether an input field is required.
SDL AST types are exported.
Support is added for symbol.toStringTag.
Performance 2
Introspection query performance is improved.
The package is marked as side-effect free, which bundlers can use when optimizing imports.
Behavior and default changes 2
introspectionFromSchema now has default options.
validate works on SDL definitions.
Fixes and other changes 6
Memory leaks and infinite recursion in buildSchema are fixed.
Fixes are made for custom enum types.
extendSchema supports spec-compliant SDL extensions.
Parsing supports new schema extensions, and extendSchema supports spec-compliant SDL extensions.
validateSchema works with schema extensions.
The watch command is fixed.