-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Consolidate error properties #12396
base: jerel/rxjs
Are you sure you want to change the base?
Consolidate error properties #12396
Conversation
🦋 Changeset detectedLatest commit: d77e202 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
commit: |
@@ -5174,14 +5169,6 @@ describe("ApolloClient", () => { | |||
}); | |||
|
|||
describe("refetchQueries", () => { | |||
let consoleWarnSpy: jest.SpyInstance; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is unrelated to the errors
change, but fixes a flake that's been driving me nuts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:nod:
56937ce
to
a8800ff
Compare
a8800ff
to
a550a44
Compare
a550a44
to
aec740b
Compare
error: | ||
fetchResult.errors ? | ||
new ApolloError({ graphQLErrors: fetchResult.errors }) | ||
: undefined, | ||
variables, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this happen in ApolloClient.subscribe
to be consistent with .query
and .mutate
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One question about consistency for subscriptions, but assuming you want to keep it this way: ✅
Removes the
errors
from all derived result types and consolidates on theerror
property thoughout the client. This is a precursor to #12200 which will do work to split upApolloError
into separate types.