# Buggy code
async def __call__(
    self,
    parent_result: Optional[Any],
    args: Dict[str, Any],
    ctx: Optional[Dict[str, Any]],
    info: "Info",
) -> (Any, Any):
    try:
        default_args = self._schema_field.get_arguments_default_values()
        default_args.update(
            {argument.name: argument.value for argument in args.values()}
        )

        result = await self._func(parent_result, default_args, ctx, info)
        if info.execution_ctx.is_introspection:
            result = await self._introspection(result, ctx, info)
        return result, self._coercer(result, info)
    except Exception as e:  # pylint: disable=broad-except
        return e, None


# Traceback (tartiflette.types.exceptions.tartiflette.UnexpectedASTNode)
Traceback (most recent call last):
File "/usr/local/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/usr/local/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/usr/src/app/***/__main__.py", line 10, in <module>
sys.exit(run())
File "/usr/src/app/***/app.py", line 425, in run
"utils/sdl-generator/schema.sdl",
File "/usr/src/app/***/engines/tartiflette.py", line 70, in __init__
error_coercer=_error_coercer,
File "/usr/local/lib/python3.7/site-packages/tartiflette/engine.py", line 26, in __init__
schema_name, custom_default_resolver, exclude_builtins_scalars
File "/usr/local/lib/python3.7/site-packages/tartiflette/schema/bakery.py", line 41, in bake
schema = SchemaBakery._preheat(schema_name, exclude_builtins_scalars)
File "/usr/local/lib/python3.7/site-packages/tartiflette/schema/bakery.py", line 21, in _preheat
build_graphql_schema_from_sdl(sdl, schema=schema)
File "/usr/local/lib/python3.7/site-packages/tartiflette/sdl/builder.py", line 30, in build_graphql_schema_from_sdl
sdl, parse_graphql_sdl_to_ast(sdl), schema=schema
File "/usr/local/lib/python3.7/site-packages/tartiflette/sdl/builder.py", line 76, in transform_ast_to_schema
transformer.transform(raw_ast)
File "/usr/local/lib/python3.7/site-packages/lark/visitors.py", line 93, in transform
tree = t.transform(tree)
File "/usr/local/lib/python3.7/site-packages/lark/visitors.py", line 107, in transform
subtree.children = list(self._transform_children(subtree.children))
File "/usr/local/lib/python3.7/site-packages/lark/visitors.py", line 44, in _transform_children
yield self._transform_tree(c) if isinstance(c, Tree) else c
File "/usr/local/lib/python3.7/site-packages/lark/visitors.py", line 103, in _transform_tree
return self._call_userfunc(tree)
File "/usr/local/lib/python3.7/site-packages/lark/visitors.py", line 37, in _call_userfunc
return f(tree)
File "/usr/local/lib/python3.7/site-packages/lark/visitors.py", line 232, in f
return _f(self, *args, **kwargs)
File "/usr/local/lib/python3.7/site-packages/tartiflette/sdl/transformers/schema_transformer.py", line 389, in input_value_definition
child, child.__class__.__name__
tartiflette.types.exceptions.tartiflette.UnexpectedASTNode: Unexpected AST node `SchemaNode(type='directives', value={'maxLength': {'limit': 512}})`, type `SchemaNode`

# Fixed code
async def __call__(
    self,
    parent_result: Optional[Any],
    args: Dict[str, Any],
    ctx: Optional[Dict[str, Any]],
    info: "Info",
) -> (Any, Any):
    try:
        result = await self._func(
            parent_result,
            await coerce_arguments(self._schema_field.arguments, args, ctx, info),
            ctx,
            info,
        )

        if info.execution_ctx.is_introspection:
            result = await self._introspection(result, ctx, info)
        return result, self._coercer(result, info)
    except Exception as e:  # pylint: disable=broad-except
        return e, None