Skip to content

Latest commit

 

History

History
1264 lines (741 loc) · 42 KB

File metadata and controls

1264 lines (741 loc) · 42 KB

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

You can find and compare releases at the GitHub release page.

Unreleased

v15.32.3

Fixed

v15.32.2

Fixed

v15.32.1

Fixed

  • Fix "Cannot traverse an already closed generator" in Schema::getTypeMap() webonyx#1903

v15.32.0

Added

  • Implement AmpFutureAdapter for integration with AMPHP v3 webonyx#1900

v15.31.5

Fixed

v15.31.4

Changed

  • Prioritize count error over null error in @oneOf coercion webonyx#1891

v15.31.3

Fixed

  • Apply per-schema built-in scalar overrides without assertValid() webonyx#1886

v15.31.2

Changed

  • Exclusively support types for per-schema built-in scalar overrides, not typeLoader webonyx#1884

Fixed

  • Fix parseLiteral not called on per-schema built-in scalar overrides for inline arguments webonyx#1880

v15.31.1

Fixed

  • Fix variable validation and input coercion for per-schema scalar overrides webonyx#1876

v15.31.0

Added

  • Support per-schema scalar overrides via types config or typeLoader, without global side effects webonyx#1869
  • Add Type::builtInScalars() and Type::BUILT_IN_SCALAR_NAMES aligning with GraphQL spec terminology webonyx#1869
  • Add Directive::builtInDirectives() and Directive::isBuiltInDirective() aligning with GraphQL spec terminology webonyx#1869

Deprecated

  • Deprecate Type::overrideStandardTypes() in favor of per-schema scalar overrides webonyx#1869
  • Deprecate Type::getStandardTypes() in favor of Type::builtInScalars() webonyx#1869
  • Deprecate Type::STANDARD_TYPE_NAMES in favor of Type::BUILT_IN_SCALAR_NAMES webonyx#1869
  • Deprecate Directive::getInternalDirectives() in favor of Directive::builtInDirectives() webonyx#1869
  • Deprecate Directive::isSpecifiedDirective() in favor of Directive::isBuiltInDirective() webonyx#1869

v15.30.2

Fixed

  • Use PHP 7.4 compatible syntax in attribute classes webonyx#1847

v15.30.1

Changed

  • Improve performance 6% by lessening is_array and instanceof checks webonyx#1845

v15.30.0

Added

v15.29.4

Fixed

  • Fix query complexity for fragments defined after operations webonyx#1826

v15.29.3

Changed

  • Remove pass-by-reference for $result in ReferenceExecutor webonyx#1780

v15.29.2

Fixed

  • Do not escape forward slashes in Printer::printDescription webonyx#1824

v15.29.1

Fixed

v15.29.0

Changed

Deprecated

  • Deprecate GraphQL\Deferred::create() in favor of constructor webonyx#1805

v15.28.0

Changed

v15.27.2

Fixed

  • Fix PHP 7.4 compatibility broken by \Stringable interface webonyx#1810

v15.27.1

Fixed

v15.27.0

Added

  • Optimize Deferred memory usage with incremental queue processing webonyx#1790

v15.26.0

Changed

  • Ignore Introspection queries in QueryComplexity rule webonyx#1788

v15.25.2

Fixed

  • Add missing return types in HasFieldsTypeImplementation webonyx#1783

v15.25.1

Changed

  • Call AbstractType::resolveValue before AbstractType::resolveType webonyx#1781

v15.25.0

Added

  • Introduce resolveValue method to Interface and Union types webonyx#1776

v15.24.0

Added

v15.23.1

Changed

v15.23.0

Added

  • Allow replacing a Node with a NodeList in Visitor webonyx#1754

v15.22.4

Fixed

v15.22.3

Changed

v15.22.2

Fixed

  • Do not escape forward slashes in Printer::doPrint webonyx#1748

v15.22.1

Fixed

  • Keep isOneOf directive when extending input objects with SchemaExtender webonyx#1745

v15.22.0

Added

Changed

v15.21.3

Fixed

  • Make querying isOneOf optional in introspection query webonyx#1737

v15.21.2

Fixed

v15.21.1

Fixed

v15.21.0

Added

  • Add support for @oneOf input object directive - enables "input unions" where exactly one field must be provided webonyx#1715

v15.20.1

Fixed

  • Avoid unnecessary @throws annotations for known correct configuration webonyx#1716

v15.20.0

Added

  • Add keys type and unions to ResolveInfo::getFieldSelectionWithAliases result webonyx#1681

v15.19.1

Fixed

  • Handle fields that return lists in ResolveInfo::getFieldSelectionWithAliases webonyx#1664

v15.19.0

Added

  • Add method getFieldSelectionWithAliases to class ResolveInfo webonyx#1648

v15.18.1

Fixed

  • Reset static caches of instances using standard types when overriding them webonyx#1632

v15.18.0

Added

  • Propagate error messages of client-safe exceptions during parseValue webonyx#1624

v15.17.0

Added

v15.16.1

Fixed

v15.16.0

Added

  • Create field args mapper and cache args resolution webonyx#1587

v15.15.0

Added

  • Add field config decorator when building schema from SDL webonyx#1590

v15.14.3

Fixed

  • Serialize BackedEnum instances by name, not value webonyx#1618

v15.14.2

Changed

  • Annotate return value of Helper::validateOperationParams as list webonyx#1615

v15.14.1

Changed

  • Narrow type of execution errors from array to list webonyx#1597

v15.14.0

Added

  • Allow native PHP enums as return values for SDL-based enums webonyx#1608

v15.13.0

Added

  • Serialize valid \BackedEnum values in GraphQL\Type\Definition\PhpEnumType webonyx#1604

v15.12.5

Fixed

  • Avoid infinite recursion in QueryDepth validator webonyx#1581

v15.12.4

Fixed

  • Ensure unaliasedPath does not grow for each list item webonyx#1579

v15.12.3

Fixed

  • Avoid crash by triggering side effect via count on PHPUnit\Framework\Test webonyx#1577

v15.12.2

Changed

v15.12.1

Fixed

v15.12.0

Added

v15.11.2

Fixed

v15.11.1

Fixed

  • Count new lines when parsing multi-line comments webonyx#1538

v15.11.0

Changed

  • Allow scalars from BuildClientSchema to have any type webonyx#1536

v15.10.0

Changed

  • The standard server now produces distinct exception classes instead of generic RequestError webonyx#1533

v15.9.1

Fixed

  • Allow enum instances in PhpEnumType::parseValue() webonyx#1519

v15.9.0

Added

v15.8.1

Fixed

  • Correctly print deprecated argument with default value webonyx#1491

v15.8.0

Added

Fixed

  • Fix PHPStan definition for SchemaConfig option types webonyx#1479

v15.7.0

Added

  • Control field visibility through option visible webonyx#1434

v15.6.3

Fixed

  • Fix printing of single line descriptions with Unicode webonyx#1436

v15.6.2

Fixed

  • Avoid instantiations when checking if types are built-in webonyx#1423

v15.6.1

Fixed

  • Allow lazy root type callables to return null webonyx#1422

v15.6.0

Added

  • Allow lazy root types query, mutation, subscription webonyx#1418

v15.5.3

Fixed

  • Also set queryId from Apollo-source sha256Hash if query is provided webonyx#1412

v15.5.2

Fixed

  • Do not set raw vars on query complexity rule if no validation rules are used webonyx#1413

v15.5.1

Fixed

  • Remove useless and broken Parser::document(), use parse()

v15.5.0

Added

  • Add ScopedContext interface to control cloning of the context value

v15.4.0

Added

v15.3.2

Fixed

  • Call static methods in SchemaPrinter with static:: to enable overrides

v15.3.1

Fixed

  • Allow sending both query and queryId, let persistedQueryLoader handle it webonyx#1372

v15.3.0

Added

  • Provide a custom name for the Enum generated by PhpEnumType webonyx#1368

v15.2.5

Fixed

  • Merge selected fields in ResolveInfo::getFieldSelection() webonyx#1365

v15.2.4

Fixed

  • Ensure OperationDefinitionNode.variableDefinitions is initialized

v15.2.3

Fixed

  • Annotate @throws accurately

v15.2.2

Fixed

  • Improve handling of JSON encoding errors

v15.2.1

Fixed

  • Initialize directives and arguments in Node with empty NodeList

v15.2.0

Changed

  • Improve validation messages for type definitions

v15.1.0

Added

  • Add additional sorting options to SchemaPrinter

v15.0.3

Fixed

  • Fix QueryPlan for union types

Changed

  • Improve QueryPlan performance

v15.0.2

Fixed

  • Fix QueryPlan when querying __typename on a union type

v15.0.1

Fixed

  • Fix printing of single line descriptions with backslashes

Changed

  • Print long argument lists on multiple lines
  • Print space between object value brackets

v15.0.0

Changed

  • PHP version required: 7.4+
  • Propagate error message and stack trace for why leaf value serialization failed
  • Do not throw client safe Error when failing to serialize an Enum type
  • Use native PHP types for properties of Type and its subclasses
  • Throw SerializationError over client safe Error when failing to serialize leaf types
  • Move debug entries in errors under extensions key
  • Use native PHP types wherever possible
  • Always throw RequestError with useful message when clients provide an invalid JSON body
  • Move class BlockString from namespace GraphQL\Utils to GraphQL\Language
  • Return string-keyed arrays from GraphQL::getStandardDirectives(), GraphQL::getStandardTypes() and GraphQL::getStandardValidationRules()
  • Move complexity related code from FieldDefinition to QueryComplexity
  • Exclude unused standard types from the schema
  • Require lazy type loader to return Type directly without an intermediary callable
  • Allow lazy type loader to return null
  • Rename ServerConfig option persistentQueryLoader to persistedQueryLoader
  • Call previously unused methods EnumType::parseValue() and EnumType::parseLiteral()
  • Strongly type PromiseAdapter::createRejected() to require \Throwable
  • Move members specific to NamedType out of Type: $name, $description, $config, isBuiltInType(), assertValid()
  • Always convert recursively when calling Node::toArray()
  • Make Directive::$config['args'] use the same definition style as FieldDefinition::$config['args']
  • Rename FieldArgument to Argument
  • Make errors when parsing scalar literals more precise
  • Change expected QueryPlan options from ['group-implementor-fields'] to ['groupImplementorFields' => true] in ResolveInfo::lookAhead()
  • Always convert promises through PromiseAdapter::convertThenable() before calling ->then() on them
  • Use JSON_THROW_ON_ERROR in json_encode()
  • Validate some internal invariants through assert()
  • PromiseAdapter::all() accepts iterable
  • Throw if Introspection::fromSchema() returns no data
  • Reorganize abstract class ASTValidationContext to interface ValidationContext
  • Reorganize AST interfaces related to schema and type extensions
  • Align Utils::suggestionList() with the reference implementation (webonyx#1075)
  • Order schema topologically and according to the user-defined order, affects introspection and printing
  • GraphQL\Utils\AST::typeFromAST() now needs a type loader callable instead of the Schema
  • Do not change HTTP status code in StandardServer
  • Use " instead of """ for single line descriptions
  • Make Helper::emitResponse() private, use Helper::sendResponse()
  • Emit unescaped UTF-8 from StandardServer
  • Sync input value coercion with graphql-js reference implementation
  • Store rules exclusively by class name in DocumentValidator
  • Reorder standard types as described in the GraphQL specification
  • Improve runtime performance by moving checks for duplicate/mismatching type instances to assert() or schema validation
  • Replace HasSelectionSet::$selectionSet with HasSelectionSet::getSelectionSet()
  • Replace TypeDefinitionNode::$name with TypeDefinitionNode::getName()
  • Replace TypeExtensionNode::$name with TypeExtensionNode::getName()

Added

  • Improve extendability of validator rules
  • Add tests for errors that occur when undeclared fields are passed in input
  • Warn about orphaned object types
  • Expose structured enumeration of directive locations
  • Add AST::concatAST() utility
  • Allow lazy input object fields
  • Add validation rule UniqueEnumValueNames
  • Add SDL validation rule UniqueOperationTypes (webonyx#995)
  • Add ability to remove custom validation rules after adding them via DocumentValidator::removeRule()
  • Allow lazy enum values
  • Make Node implement JsonSerializable
  • Add SDL validation rule UniqueTypeNames (webonyx#998)
  • Add support for SDL validation to KnownTypeNames rule (webonyx#999)
  • Add SDL validation rule UniqueArgumentDefinitionNames (webonyx#1136)
  • Add parseValue config option to InputObjectType to parse input value to custom value object
  • Add option sortTypes to have SchemaPrinter order types alphabetically
  • Allow constructing EnumType from PHP enum
  • Add TypeInfo::getParentTypeStack() and TypeInfo::getFieldDefStack()
  • Include path to faulty input in coercion errors
  • Add ability to resolve abstract type of object via __typename

Optimized

  • Use recursive algorithm for printer and improve its performance
  • Use foreach over slower functions array_map() and Utils::map()

Fixed

  • Avoid QueryPlan crash when multiple $fieldNodes are present
  • Allow instantiating multiple QueryPlan with different options
  • Clarify error when attempting to coerce anything but array or stdClass to an input object
  • Allow directives on variable definitions
  • Handle null parent of list in ValuesOfCorrectType::getVisitor
  • Allow sending both query and queryId, ignore queryId in that case
  • Preserve extended methods from class-based types in SchemaExtender::extend()
  • Fix printing of empty types (webonyx#940)
  • Clone NodeList in Node::cloneDeep()
  • Calling Schema::getType() on a schema built from SDL returns null for unknown types (webonyx#1068)
  • Avoid crash on typeless inline fragment when using QueryComplexity rule
  • Avoid calling FormattedError::addDebugEntries() twice when using default error formatting
  • Avoid calling defined functions named like lazily loaded types
  • Show actual error in debug entries
  • Deal with iterable in implementations of PromiseAdapter::all()

Removed

  • Remove OperationParams method getOriginalInput() in favor of public property $originalInput
  • Remove OperationParams method isReadOnly() in favor of public property $readOnly
  • Remove Utils::withErrorHandling()
  • Remove TypeComparators::doTypesOverlap()
  • Remove DocumentValidator::isError()
  • Remove DocumentValidator::append()
  • Remove Utils::getVariableType() in favor of Utils::printSafe()
  • Remove warning for passing isDeprecated in field definition config
  • Remove WrappingType::getWrappedType() argument $recurse in favor of WrappingType::getInnermostType()
  • Remove Type::assertType()
  • Remove ListOfType::$ofType, ListOfType::getOfType() and NonNull::getOfType()
  • Remove option commentDescriptions from BuildSchema::buildAST(), BuildSchema::build() and Printer::doPrint()
  • Remove parameter $options from ASTDefinitionBuilder
  • Remove FieldDefinition::create() in favor of new FieldDefinition()
  • Remove GraphQL\Exception\InvalidArgument
  • Remove Utils::find(), Utils::every() and Utils::invariant()
  • Remove argument bool $exitWhenDone from StandardServer::send500Error() and StandardServer::handleRequest()
  • Remove Schema::getAstNode() in favor of Schema::$astNode
  • Remove ability to override standard types through Schema option types, use Type::overrideStandardTypes()
  • Remove GraphQL\Utils\TypeInfo::typeFromAST(), use GraphQL\Utils\AST::typeFromAST()
  • Remove StandardServer::send500Error(), handle non-GraphQL errors yourself
  • Remove StandardServer::getHelper(), use new Helper
  • Remove error extension field category, use custom error formatting if you still need it
  • Remove deprecated Type::getInternalTypes()
  • Remove deprecated GraphQL::execute()
  • Remove deprecated GraphQL::executeAndReturnResult()
  • Remove deprecated experimental CoroutineExecutor
  • Remove deprecated FormattedError::create() and FormattedError::createFromPHPError()
  • Remove deprecated GraphQL::setPromiseAdapter()
  • Remove deprecated AST::getOperation()
  • Remove deprecated constants from BreakingChangesFinder
  • Remove deprecated DocumentValidator::isValidLiteralValue()
  • Remove deprecated Error::formatError() and Error::toSerializableArray()
  • Remove deprecated GraphQL::getInternalDirectives()
  • Remove deprecated Schema::isPossibleType()
  • Remove deprecated methods from TypeInfo
  • Remove deprecated Values::valueFromAST() and Values::isValidPHPValue()
  • Remove deprecated public property access to InputObjectField::$type
  • Remove deprecated public property access to FieldDefinition::$type
  • Remove alias GraphQL\Validator\Rules\AbstractQuerySecurity, use GraphQL\Validator\Rules\QuerySecurityRule
  • Remove alias GraphQL\Validator\Rules\AbstractValidationRule, use GraphQL\Validator\Rules\ValidationRule
  • Remove alias GraphQL\Utils\FindBreakingChanges, use GraphQL\Utils\BreakingChangesFinder

v14.11.10

Fixed

  • Fix PHP 8.2 deprecated string interpolation syntax
  • Fix PHP 8.2 deprecated dynamic properties

v14.11.9

Fixed

  • Accept AST where field arguments are not given

v14.11.8

Fixed

v14.11.7

Fixed

  • Fix PHP 8.2 deprecation of "static" in callables

v14.11.6

Fixed

  • Fix validation of modified sparse ASTs

v14.11.5

Fixed

v14.11.4

Fixed

  • Fix repeatable directive validation for AST

v14.11.3

Fixed

  • Fix compatibility of more methods with native return type in PHP 8.1

v14.11.2

Fixed

  • Support non-JSON ServerRequestInterface

v14.11.1

Fixed

  • Fix compatibility of methods with native return type in PHP 8.1

v14.11.0

Added

  • Allow field definitions to be defined as any iterable, not just array

v14.10.0

Added

  • Make IntType constants MAX_INT and MIN_INT public

v14.9.0

Added

  • Add support for type config decorator in SchemaExtender

v14.8.0

Added

  • Implement GraphQL\Utils\AST::getOperationAST()

v14.7.0

Added

  • Allow providing field definitions as a callable and resolve them lazily

v14.6.4

Fixed

  • Avoid crashing in QueryPlan when __typename is used in the query

v14.6.3

Refactoring:

  • Improve performance of subtype checks

v14.6.2

Fixed

  • Fix overly eager validation of repeatable directive usage

v14.6.1

Fixed

  • Add fallback for directive.isRepeatable in BuildClientSchema

v14.6.0

Added

  • Open ReferenceExecutor for extending

Fixed

  • Ensure properties annotated to hold NodeList are not null
  • Validate that directive argument names do not use reserved or duplicate names

v14.5.1

Fixed

  • Fix Input Object field shortcut definition with callable (webonyx#773)

v14.5.0

Added

  • Implement support for interfaces implementing interfaces (webonyx#740), huge kudos to @Kingdutch

Deprecates:

  • Constant BreakingChangeFinder::BREAKING_CHANGE_INTERFACE_REMOVED_FROM_OBJECT. Use BreakingChangeFinder::BREAKING_CHANGE_IMPLEMENTED_INTERFACE_REMOVED instead. Constant value also changed from INTERFACE_REMOVED_FROM_OBJECT to IMPLEMENTED_INTERFACE_REMOVED.

  • Constant BreakingChangeFinder::DANGEROUS_CHANGE_INTERFACE_ADDED_TO_OBJECT Use DANGEROUS_CHANGE_IMPLEMENTED_INTERFACE_ADDED instead. Constant value also changed from INTERFACE_ADDED_TO_OBJECT to IMPLEMENTED_INTERFACE_ADDED.

Refactoring:

  • Reify AST node types and remove unneeded nullability (webonyx#751)

v14.4.1

Fixed

  • Allow pushing nodes to NodeList via []= (webonyx#767)
  • Fix signature of Error\FormattedError::prepareFormatter() to address PHP8 deprecation (webonyx#742)
  • Do not add errors key to result when errors discarded by custom error handler (webonyx#766)

v14.4.0

Fixed

  • Fixed SchemaPrinter so that it uses late static bindings when extended
  • Parse DirectiveDefinitionNode->locations as NodeList<NamedNode> (fixes AST::fromArray conversion) (webonyx#723)
  • Parse Parser::implementsInterfaces as NodeList<NamedTypeNode> (fixes AST::fromArray conversion)
  • Fix signature of Parser::unionMemberTypes to match actual NodeList<NamedTypeNode>

v14.3.0

Added

  • Allow typeLoader to return a type thunk (webonyx#687)

Fixed

  • Read getParsedBody() instead of getBody() when Request is ServerRequest (webonyx#715)
  • Fix default get/set behavior on InputObjectField and FieldDefinition (webonyx#716)

v14.2.0

Deprecates:

  • Public access to FieldDefinition::$type property (webonyx#702)

Fixes:

  • Fix validation for input field definition directives (webonyx#714)

v14.1.1

v14.1.1

Fixed

  • Handle nullable DirectiveNode#astNode in SchemaValidationContext (webonyx#708)

v14.1.0

Added

  • Add partial parse functions for const variants (webonyx#693)

Fixed

  • Differentiate between client-safe and non-client-safe errors in scalar validation (webonyx#706)
  • Proper type hints for IntValueNode (webonyx#691)
  • Fix "only booleans are allowed" errors (webonyx#659)
  • Ensure NamedTypeNode::$name is always a NameNode (webonyx#695)

Optimized

v14.0.2

Optimized

v14.0.1

Fixed

  • Fix for: Argument defaults with integer/float values crashes introspection query (webonyx#679)
  • Fix for "Invalid AST Node: false" error (webonyx#685)
  • Fix double Error wrapping when parsing variables (webonyx#688)

Optimized

v14.0.0

This release brings several breaking changes. Please refer to UPGRADE document for details.

  • BREAKING/BUGFIX: Strict coercion of scalar types (webonyx#278)
  • BREAKING/BUGFIX: Spec-compliance: Fixed ambiguity with null variable values and default values (webonyx#274)
  • BREAKING: Removed deprecated directive introspection fields (onOperation, onFragment, onField)
  • BREAKING: GraphQL\Deferred now extends GraphQL\Executor\Promise\Adapter\SyncPromise
  • BREAKING: renamed several types of dangerous/breaking changes (returned by BreakingChangesFinder)
  • BREAKING: Renamed GraphQL\Error\Debug to GraphQL\Error\DebugFlag.
  • BREAKING: Debug flags in GraphQL\Executor\ExecutionResult, GraphQL\Error\FormattedError and GraphQL\Server\ServerConfig do not accept boolean value anymore but int only.
  • BREAKING: $positions in GraphQL\Error\Error constructor are not nullable anymore. Same can be expressed by passing an empty array.

Added

Changed

  • Compliant with the GraphQL specification June 2018 Edition
  • Having an empty string in deprecationReason will now print the @deprecated directive (only a null deprecationReason won't print the @deprecated directive).

Optimized

  • Perf: support lazy type definitions (webonyx#557)
  • Simplified Deferred implementation (now allows chaining like promises, webonyx#573)

Deprecated

Fixed

  • Some bugs
  • Improve accuracy of type hints with PHPStan

Special thanks to @simPod, @spawnia and @shmax for their major contributions!

v0.13.9

  • Fix double Error wrapping when parsing variables (webonyx#689)

v0.13.8

  • Don't call global field resolver on introspection fields (webonyx#481)

v0.13.7

  • Added retrieving query complexity once query has been completed (webonyx#316)
  • Allow input types to be passed in from variables using \stdClass instead of associative arrays (webonyx#535)

v0.13.6

  • QueryPlan can now be used on interfaces not only objects. (webonyx#495)
  • Array in variables in place of object shouldn't cause fatal error (fixes webonyx#467)
  • Scalar type ResolverInfo::getFieldSelection support (webonyx#529)

v0.13.5

  • Fix coroutine executor when using with promise (webonyx#486)

v0.13.4

v0.13.3

  • Reverted minor possible breaking change (webonyx#476)

v0.13.2

  • Added QueryPlan support (webonyx#436)
  • Fixed an issue with NodeList iteration over missing keys (webonyx#475)

v0.13.1

  • Better validation of field/directive arguments
  • Support for apollo client/server persisted queries
  • Minor tweaks and fixes

v0.13.0

This release brings several breaking changes. Please refer to UPGRADE document for details.

New features and notable changes:

  • PHP version required: 7.1+
  • Spec compliance: error category and extensions are displayed under extensions key when using default formatting (webonyx#389)
  • New experimental executor with improved performance (webonyx#314).
    It is a one-line switch: GraphQL::useExperimentalExecutor().

    Please try it and post your feedback at webonyx#397 (as it may become the default one in future)

  • Ported extendSchema from the reference implementation under GraphQL\Utils\SchemaExtender (webonyx#362)
  • Added ability to override standard types via GraphQL::overrideStandardTypes(array $types) (webonyx#401)
  • Added flag Debug::RETHROW_UNSAFE_EXCEPTIONS which would only rethrow app-specific exceptions (webonyx#337)
  • Several classes were renamed (see UPGRADE.md)
  • Schema Validation improvements

v0.12.6

  • Bugfix: Call to a member function getLocation() on null (webonyx#336)
  • Fixed several errors discovered by static analysis (webonyx#329)

v0.12.5

  • Execution performance optimization for lists

v0.12.4

  • Allow stringeable objects to be serialized by StringType (webonyx#303)

v0.12.3

  • StandardServer: add support for the multipart/form-data content type (webonyx#300)

v0.12.2

  • SchemaPrinter: Use multi-line block for trailing quote (webonyx#294)

v0.12.1

  • Fixed bug in validation rule OverlappingFieldsCanBeMerged (webonyx#292)
  • Added one more breaking change note in UPGRADE.md (webonyx#291)
  • Spec compliance: remove data entry from response on top-level error (webonyx#281)

v0.12.0

  • RFC: Block String (multi-line strings via triple-quote """string""")
  • GraphQL Schema SDL: Descriptions as strings (including multi-line)
  • Changed minimum required PHP version to 5.6

Improvements:

  • Allow extending GraphQL errors with additional properties
  • Fixed parsing of default values in Schema SDL
  • Handling several more cases in findBreakingChanges
  • StandardServer: expect operationName (instead of operation) in input

v0.11.5

  • Allow objects with __toString in IDType

v0.11.4

v0.11.3

  • StandardServer: Support non pre-parsed PSR-7 request body (see webonyx#202)

v0.11.2

  • Bugfix: provide descriptions to custom scalars (see webonyx#181)

v0.11.1

  • Ability to override internal types via types option of the schema (see webonyx#174).

v0.11.0

This release brings little changes but there are two reasons why it is released as major version:

  1. To follow reference implementation versions (it matches 0.11.x series of graphql-js)
  2. It may break existing applications because scalar input coercion rules are stricter now:
    In previous versions sloppy client input could leak through with unexpected results. For example string "false" accidentally sent in variables was converted to boolean true and passed to field arguments. In the new version, such input will produce an error (which is a spec-compliant behavior).

Improvements:

  • Stricter input coercion (see webonyx#171)
  • Types built with BuildSchema now have reference to AST node with corresponding AST definition (in $astNode property)
  • Account for query offset for error locations (e.g. when query is stored in .graphql file)

v0.10.2

  • StandardServer improvement: do not raise an error when variables are passed as empty string (see webonyx#156)

v0.10.1

v0.10.0

This release brings several breaking changes. Please refer to UPGRADE document for details.

New features and notable changes:

  • Changed minimum PHP version from 5.4 to 5.5
  • Lazy loading of types without separate build step (see webonyx#69, see docs)
  • PSR-7 compliant Standard Server (see docs)
  • New default error formatting, which does not expose sensitive data (see docs)
  • Ability to define custom error handler to filter/log/re-throw exceptions after execution (see docs)
  • Allow defining schema configuration using objects with fluent setters vs array (see docs)
  • Allow serializing AST to array and re-creating AST from array lazily (see docs)
  • Apollo-style query batching support via server (see docs)
  • Schema validation, including validation of interface implementations (see docs)
  • Ability to pass custom config formatter when defining schema using GraphQL type language (see docs)

Improvements:

Deprecations and breaking changes - see UPGRADE document.

v0.9.14

  • Minor change to assist DataLoader project in fixing webonyx#150

v0.9.13

  • Fixed PHP notice and invalid conversion when non-scalar value is passed as ID or String type (see webonyx#121)

v0.9.12

  • Fixed bug occurring when enum value is bool, null or float (see webonyx#141)

v0.9.11

v0.9.10

  • Fixed issue with query complexity throwing on invalid queries (see webonyx#125)
  • Fixed "Out of memory" error when resolveType returns unexpected result (see webonyx#119)

v0.9.9

  • Bugfix: throw UserError vs InvariantViolationError for errors caused by client (see webonyx#123)

v0.9.8

  • Bugfix: use directives when calculating query complexity (see webonyx#113)
  • Bugfix: AST\Node::__toString() will convert node to array recursively to encode to json without errors

v0.9.7

  • Bugfix: ResolveInfo::getFieldSelection() now correctly merges fragment selections (see webonyx#98)

v0.9.6

  • Bugfix: ResolveInfo::getFieldSelection() now respects inline fragments

v0.9.5

  • Fixed SyncPromiseAdapter::all() to not change the order of arrays (see webonyx#92)

v0.9.4

  • Tools to help building schema out of Schema definition language as well as printing existing schema in Schema definition language (see webonyx#91)

v0.9.3

  • Fixed Utils::assign() bug related to detecting missing required keys (see webonyx#89)

v0.9.2

  • Schema Definition Language: element descriptions can be set through comments (see webonyx#88)

v0.9.1

  • Fixed: GraphQL\Server now properly sets promise adapter before executing query

v0.9.0

  • Deferred resolvers (see webonyx#66, see docs)
  • New Facade class with fluid interface: GraphQL\Server (see webonyx#82)
  • Experimental: ability to load types in Schema lazily via custom TypeResolutionStrategy (see webonyx#69)

v0.8.0

This release brings several minor breaking changes. Please refer to UPGRADE document for details.

New features:

  • Support for null value (as required by latest GraphQL spec)
  • Shorthand definitions for field and argument types (see webonyx#47)
  • path entry in errors produced by resolvers for better debugging
  • resolveType for interface/union is now allowed to return string name of type
  • Ability to omit name when extending type class (vs defining inline)

Improvements:

  • Spec compliance improvements
  • New docs and examples

Older versions

Look at GitHub Releases Page.