You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
If my subgraph is in a nested entity fetch query plan and the subgraph has a service error or is offline, the GraphQL errors reported from Router do not have a path assigned.
To Reproduce
Router version 1.35.0
Compose a supergraph of two schemas but only start up the server of the first subgraph that has the root resolver
In older versions of Router this query plan path made into the GraphQL error path which is invalid
However in the error block there is not reference to fieldB and it's path even though it is the causing the error from the Router perspective
Expected behavior
All GraphQL errors have an associated path if we can process the request and send requests to subgraphs
Output
Router 1.35.0
Desktop (please complete the following information):
OS: MacOS
Version 14.3
Additional context
In previous versions of Router, 1.19.0, we actually has an invalid path that included the at @ symbol from query plans (which brought up this spec clarification graphql/graphql-spec#1073)
Router 1.19.0
For Router 1.35.0
Running this graph: https://github.com/apollosolutions/retail-supergraph
If we follow the spec strictly then we should have an error for every single searchProducts.1-n.reccomendProducts.1-n.reviews field but that seems excesive. So maybe we default to just returning one error for searchProducts.0.reccomendProducts.0.reviews?
But in other places we return the FetchError. Which might explain why you get the error path for some errors but not others.
And as you said, we should post process the error path to replace the @ and apply to every index in array
Describe the bug
If my subgraph is in a nested entity fetch query plan and the subgraph has a service error or is offline, the GraphQL errors reported from Router do not have a
path
assigned.To Reproduce
Router version
1.35.0
Flatten
across a list[email protected]
fieldB
and it's path even though it is the causing the error from the Router perspectiveExpected behavior
All GraphQL errors have an associated
path
if we can process the request and send requests to subgraphsOutput
Router 1.35.0
Desktop (please complete the following information):
Additional context
In previous versions of Router,
1.19.0
, we actually has an invalid path that included the at@
symbol from query plans (which brought up this spec clarification graphql/graphql-spec#1073)Router 1.19.0
For Router
1.35.0
Here is the query:
Query plan
The text was updated successfully, but these errors were encountered: