Skip to content

Invalid AST Node: false #685

@shmax

Description

@shmax

@vladar
While working on optimizations, I updated my local code to master, and am now seeing this error whenever I use an include directive:

{
  "error": {
    "message": "Invalid AST Node: false"
  }
}

It's easy to reproduce. You can run the 02-blog sample, and run this query:

{
  viewer {
    id @include (if: true)
  }
}

The culprit seems to be this commit: cab1599

Somehow, the false value returned here becomes the value of node and trips an exception here.

If I remove the boolean returns then everything starts working again, but then some of the tests fail. I thought I'd throw an issue up here to see if you have any thoughts. Thanks much.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions