Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DevTools: Correctly log errors reported from the store #22950

Merged
merged 1 commit into from
Dec 13, 2021

Conversation

jstejada
Copy link
Contributor

Summary

#22948 added (internal-only) logging to errors caught via componentDidCatch, however, this wouldn't account for the case when we handle an error reported from the store, since in that case we are manually setting the error state and that doesn't trigger componentDidCatch

In order to fix that, we also log when an error is reported by the store.

How did you test this change?

Manually throw an error from the store, verify it goes through our logging

@jstejada jstejada merged commit 5757919 into facebook:main Dec 13, 2021
@jstejada jstejada deleted the store-errors branch December 13, 2021 17:03
Copy link
Contributor

@bvaughn bvaughn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch

zhengjitf pushed a commit to zhengjitf/react that referenced this pull request Apr 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants