tartiflette v1.2.0 Release Notes
Release Date: 2020-05-02 // almost 4 years ago-
[1.2.0] - 2020-04-30
โ Added
- ISSUE-363 - Add an optional
query_cache_decorator
argument at engine initialisation allowing to forward a custom decorator to use to cache query parsing. - ISSUE-362 - Add an optional
json_loader
argument to engine creation APIs so json loader can be customized. - 0๏ธโฃ ISSUE-361 - Add an optional
custom_default_arguments_coercer
argument at engine initialisation to override the callable used to coerce arguments. - ISSUE-361 - Add an optional
arguments_coercer
to@Directive
,@Subscription
&@Resolver
decorator to override the callable used to coerce arguments on the decorated directive/field.
๐ Changed
- ๐ ISSUE-356 - Removed dependencies on
flex
andbison
for installing Tartiflette.cmake
is still necessary. - ๐ ISSUE-361 - Coerce lists (input, literal, output) synchronously to avoid creation of too many
asyncio
tasks. - ISSUE-365 - Forward the
InputValueDefinitionNode
to theon_argument_execution
hook.
โฌ๏ธ > Note: this brings a break changes from previous versions, to upgrade to
this version you'll have to update your
on_argument_execution
methods:@Directive("MyDirective") class MyDirective: async def on\_argument\_execution( self, directive\_args: Dict[str, Any], next\_directive: Callable, parent\_node: Union["FieldNode", "DirectiveNode"],+ argument\_definition\_node: "InputValueDefinitionNode",- argument\_node: "ArgumentNode",+ argument\_node: Optional["ArgumentNode"], value: Any, ctx: Optional[Any], ) -\> Any: # Write your business logic here- return next\_directive(parent\_node, argument\_node, value, ctx)+ return next\_directive(parent\_node, argument\_definition\_node, argument\_node, value, ctx)
๐ Fixed
ISSUE-370 - Fix EnumValue uniqueness in schema definition validation rule. It should now throw the correct error in the correct case.
enum anEnum { A A B}
๐ Will throw a
GraphQLSchemaError
exception atengine
build time. You can't have duplicates values.But now:
type X { afield:String}enum anEnum { Value1 X}
Doesn't throw a
GraphQLSchemaError
for the use ofX
as anEnumValue
. This was a buggy schema error detectionISSUE-372 - Fix SDL Validation, Now
ObjectFollowInterface
validator validate field arguments and allows for field type to becovariant
of the interface defined type.Typing on the documentation related to the
argument_node
argument on theon_argument_execution
directive hook. - ISSUE-363 - Add an optional