Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Queries with undefined variables are accepted by the graph-node. This is invalid as per the GraphQL spec: https://spec.graphql.org/June2018/#sec-All-Variable-Uses-Defined
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem.
Example with The Graph subgraph. Same behavior on all subgraphs.
Query:
query {
allocations(first: $first) {
id
}
}
Variables:
===> OK
What is the expected behavior?
Query:
query {
allocations(first: $first) {
id
}
}
Variables:
===> ERROR
But with
query ($first: Int) {
allocations(first: $first) {
id
}
}
===> OK
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Queries with undefined variables are accepted by the graph-node. This is invalid as per the GraphQL spec: https://spec.graphql.org/June2018/#sec-All-Variable-Uses-Defined
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem.
Example with The Graph subgraph. Same behavior on all subgraphs.
Query:
Variables:
===> OK
What is the expected behavior?
Query:
Variables:
===> ERROR
But with
===> OK