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
{{ message }}
Repository navigation
Extensions are not rendered from GraphQLError that originated from CompletableFuture #1018
I have noticed that if a DataFetcher returns a CompletableFuture, and this CompletableFuture completes exceptionally with GraphQLError as an exception, then the extensions on this GraphQLError are nor rendered to the response.
The reason is that ExecutionStrategy.handleFetchingExcetion() just delegates to
and it is never checked that the supplied Throwable may implement GraphQLError. This means that the async code can not append any custom extensions to the errors.
Activity
bbakerman commentedon May 9, 2018
I am not seeing this behaviour for extensions.
I have written a new test that shows it working (see #1037 )
Can you expand on this problem more or perhaps do a unit test that demonstrates it happening.
graphql.ExceptionWhileDataFetching#ExceptionWhileDataFetching is the class in question that transfers exceptions that are GraphqlErrors
bbakerman commentedon May 20, 2018
I am going to close this because I believe its working as expected
jaredculp commentedon Jul 29, 2021
The test referenced doesn't use a data fetcher that returns a CompletableFuture.
bbakerman commentedon Jul 30, 2021
Do you have this problem @jaredculp ? This is a very old issue and has artrofied over time.
I am not sure the code base is close enough any more. But if you can reproduce this problem please let us known?
jaredculp commentedon Aug 2, 2021
@bbakerman looks like this issue was fixed in #2371. What does your release cadence look like?
bbakerman commentedon Aug 3, 2021
17.0 is imminent