All Versions
Latest Version
Avg Release Cycle
78 days
Latest Release
858 days ago

Changelog History
Page 3

  • v1.2.2 Changes

    June 17, 2017
    • โž• Added new middleware traits MiddlewareFromScalar and MiddlewareToScalar. They provide a way to transform all scalar values from middleware (#249, #248). This have some advantages since middleware can be disable, chained together and has access to context information. Huge thanks to @BjRo and @Axxiss for helping with the feature design and implementation!
    • โž• Added new middleware trait MiddlewareExtension (#256). It provides an easy way to add extensions from middleware.
    • ๐Ÿ‘Œ Improved error message for All fields within a Type should have unique names! (#247). It now includes type and field information.
    • ๐Ÿ›  Fixed helper methods for operation lookup in ast.Document.
  • v1.2.1 Changes

    May 18, 2017
    • ๐Ÿ›  Fixed MeasureQueryDepth reducer not keeping the largest depth found (#245, #246). Big thanks @Eluinhost for this contribution!
    • Easier way to create Args (#243). Big thanks @vishalkuo for this contribution!
    • More options to render a schema (#241). This improvement is especially useful for apps that use relay modern.
  • v1.2.0 Changes

    April 29, 2017
    • ๐Ÿ“š Provide convenient functions for IDL-based schema materialization and validation (#240). For more info see the "Query Validation" section of documentation. Improvements include:
      • Introduced Schema.buildStubFromAst that builds a schema with a stub Query type
      • Introduced Schema.buildDefinitions that builds a list of definitions based on IDL AST (without a schema)
      • Introduced Document.emptyStub as a most basic, but valid document stub
      • Introduced alias query1 + query2 for document merge
    • โž• Add Fetcher.deferSeqOptExplicit or similar to explicitly get Seq[Option[T]] in the result (#230)
    • ๐Ÿ›  Fixed scalar aliases when they are used with variables or schema is extended (#237)
    • Preserve IDL directives at schema materialization time and use them in schema comparator (#236). This also adds Vector[ast.Directive] to all relevant schema definitions which may be extremely useful for future features and schema analysis
    • ๐Ÿ‘Œ Improve syntax error reporting for graphql macro (#235)
    • ๐Ÿ‘Œ Improve Int, BigInt and Long scalar value handling (#234)
    • ๐Ÿ“š Propagate updated value through middleware's afterField (#233). For more info see the "Middleware" section of documentation.
    • Forbid 'true', 'false' and 'null' as names for Enum value (#239)
  • v1.1.0 Changes

    March 11, 2017
    • โž• Added scalar type alias support (#225, #210). For more info see the "Scalar Type Alias" section of documentation.
    • Greatly improved AstVisitor (#214). It now includes helper methods to traverse and transform an AST with type info and state. Sangria now integrates with macro-visit which was specifically written to traverse and transform ASTs which are similar to sangria's. For more info see the "AstVisitor" section of documentation.
    • โž• Added DocumentAnalyzer and SchemaBasedDocumentAnalyzer that contain a lot of helper methods to analyze query. This includes newly introduced deprecatedUsages and introspectionUsages (#211, #207, #212). For more info see brand new "Query And Schema Analysis" section of documentation.
    • โž• Added QueryReducer.hasIntrospection and QueryReducer.rejectIntrospection that rejects queries which contain introspection fields (#211). This may be useful for production environments where introspection can potentially be abused.
    • โž• Added Context.isIntrospection and sangria.introspection.isIntrospection helper methods to easily distinguish between introspection types and fields in middleware and query reducers.
    • โž• Added QueryReducer.measureDepth and QueryReducer.rejectMaxDepth rejects queries that are deeper than provided threshold (In contrast to Executor.execute(maxQueryDepth = ...), query reducer does it at query analysis time before actual execution).
    • โž• Added derive* macro settings (TransformFieldNames and TransformInputFieldNames) to transform field names. (#215) Big thanks to @ostronom for this contribution.
    • โž• Added ability to represent complex relations in Fetch API (#220).
    • โšก๏ธ ExecutionScheme.Extended now returns updated user context for mutations (#209).
    • ๐Ÿ‘Œ Improved handling of tailing comments when rendering query AST (#219).
    • โž• Added aliases for graphql/graphqlInput macros: gql/gqlInp
    • Using Vector instead of List for all AST nodes now. This is a minor breaking change.
  • v1.0.0 Changes

    January 16, 2017
    • โž• Added Action.sequence combinator to compose a list of LeafActions in a single LeadAction that can be returned from a resolve function (#206)
    • ๐Ÿ‘Œ Support of Option[Id] in Fetcher.deferOpt (#205)
    • Implicit conversion from Future[Deferred[A]] to Action does not work (#201)
    • Disallow creation of object types with empty list of fields (#200)
    • SimpleFetcherCache does not cache Relation (#194)
    • Fetching Relation Typing (#193)
    • Helper method sangroia.schema.action is replaced with Action.apply and LeafAction.apply
  • v1.0.0-RC5 Changes

    November 28, 2016
    • Uphold spec for non-validation names not beginning with __ (spec-change) (#189)
    • Field cache does not consider output object polymorphism (#190)
    • โž• Added QueryReducer.measureDepth and QueryReducer.rejectMaxDepth query reducers (#191). maxQueryDepth argument was available for a long time on Executor, but in contrast to new query reducers, it measures depth along side of the execution. With query reducers it happens before query execution, thus allow to reject the query execution entirely.
    • FetcherDeferredOpt does not extends DeferredOpt (#188)
    • Invalid operation name now be considered a client-side error and now implements QueryAnalysisError (#186, #187). Big thanks to @mattfenwick for working on this one!
  • v1.0.0-RC4 Changes

    November 20, 2016

    ๐Ÿš€ Sangria v1.0.0-RC4 is fully compliant with "October 2016" version of the GraphQL specification.

    • ๐Ÿ’ฅ In presence of explicit null value, the default will not be used (#185) (spec change). Breaking change! Arguments with default values are no longer treated as non-optional arguments. Though Args still preserves existing semantics (default is still applied, even in presence of explicit null). The same is true for input objects and optional input object fields with default values.
    • โž• Added Args.withArgs and Args.argDefinedInQuery convenience methods.
    • Validation rule for unique directives per location (#179).
    • Enforces input coercion rules (#177).
    • MiddlewareQueryContext and ExecutionResult now contain information about validation and query reducers' execution time (validationTiming, queryReducerTiming)
    • Middleware.fieldError was not called in all possible exceptional situations (#184).
    • ๐Ÿ†• New QueryParser.parseInputWithVariables provides a way to parse input values with variables.
    • ๐Ÿ›  Various bugfixes in error handing of deferred values and null/undefined value handling.
  • v1.0.0-RC3 Changes

    November 05, 2016
    • Cross compile to scala 2.12 and scala 2.11 (#182, #183)
    • ๐Ÿ“š Schema comparator (#169, #165). It helps to compare different schemas or different versions of the same schema. It also provides an information whether particular change is a breaking change. This is a great example of GraphQL type system potential. For more info see the "Schema Comparator" section of documentation.
    • ๐Ÿ‘Œ Improve handling of NaN and infinity values (#167, #168)
  • v1.0.0-RC2 Changes

    October 10, 2016
    • Capture original exceptions only if necessary (based on the ExecutionScheme)
    • ๐Ÿ›  Fixed issue with duplicate errors appearing during sequential query execution (mutations)
  • v1.0.0-RC1 Changes

    October 08, 2016

    Towards 1.0!

    • ๐Ÿ“š Stream-based subscriptions (#98, #166). For more info see the "Stream-based Subscriptions" section of documentation.
    • ๐Ÿ“š High-level Fetch API for deferred value resolution (#164). For more info see the "High-level Fetch API" section of documentation.
    • ๐Ÿ“š Huge improvements in deferred value resolution (#161). Here is just an example of how batching algorithm is improved in comparison to previous version. For more info see the "Deferred Value Resolution" section of documentation. It got a lot of new content.
    • ๐Ÿ“š Introduced ExecutionScheme. It allows to change the result type of an exaction. So now you can get some meta-information about a query execution itself, and not only the Future of marshaled result. For more info see the "Alternative Execution Scheme" section of documentation.
    • Minor breaking changes:

      • DeferredResolver and Deferred are moved to sangria.execution.deferred package.
      • DeferredResolver.resolve method signature is changes a bit (2 new arguments were added). Here is the new signature:
      def resolve(deferred: Vector[Deferred[Any]], ctx: Ctx, queryState: Any)(implicit ec: ExecutionContext): Vector[Future[Any]]