Skip to content

findComponentRoot warning is misleading when logged from a transaction close #767

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

Closed
sophiebits opened this issue Dec 31, 2013 · 0 comments · Fixed by #768
Closed

findComponentRoot warning is misleading when logged from a transaction close #767

sophiebits opened this issue Dec 31, 2013 · 0 comments · Fixed by #768

Comments

@sophiebits
Copy link
Collaborator

If findComponentRoot throws an exception during a Transaction close (specifically, in ReactMountReady.notifyAll) after the body of the transaction threw an exception, then it logs an error (using console.error) immediately, like so:

image

The error it throws is silenced by Transaction.perform in favor of the earlier error thrown by the wrapped method, but the findComponentRoot error is logged first, which is misleading.

sophiebits added a commit to sophiebits/react that referenced this issue Dec 31, 2013
Fixes facebook#767. This essentially reverts 738de8c.

We could store some sort of flag to silence the console error here but since we've made significant improvements in markup wrapping, this error is fairly rare now. We'll also have validation of node structure soon in facebook#735.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant