Skip to content

Make "unexpected batch number" a warning - #7133

Merged
sophiebits merged 1 commit into
react:masterfrom
sophiebits:unexp-bat
Jun 27, 2016
Merged

Make "unexpected batch number" a warning#7133
sophiebits merged 1 commit into
react:masterfrom
sophiebits:unexp-bat

Conversation

@sophiebits

Copy link
Copy Markdown
Collaborator

This was added to catch internal errors in React but doesn't seem to be doing much good except frustrating people more when their apps throw (#6895, FB-internal t11950821). Until more proper error boundaries land, let's make this a warning.

This was added to catch internal errors in React but doesn't seem to be doing much good except frustrating people more when their apps throw (react#6895, FB-internal t11950821). Until more proper error boundaries land, let's make this a warning.
@jimfb

jimfb commented Jun 27, 2016

Copy link
Copy Markdown
Contributor

Seems reasonable. Are we sure that the "unexpected batch number" is due to prior errors in the user's application, and not due to a subtle bug in React? We've seen a bunch of super subtle/complex bugs related to this code path, and it isn't super clear to me that people are hitting this do to recoverable bugs in user land rather than a subtle bug in React land.

Regardless, I suppose there isn't really a reason to make this fatal, so this change seems reasonable.

@sophiebits

sophiebits commented Jun 27, 2016

Copy link
Copy Markdown
Collaborator Author

The two people in #6895 who saw it, saw it because of an earlier error – and we did in the FB task too. So it's possible there could be subtle bugs in React that this would catch (which is why I'm leaving it instead of removing it completely) but I don't think we've seen any evidence of that so far.

@sophiebits
sophiebits merged commit abcd567 into react:master Jun 27, 2016
@zpao zpao modified the milestones: 15-next, 15.3.0 Jul 13, 2016
zpao pushed a commit that referenced this pull request Jul 13, 2016
This was added to catch internal errors in React but doesn't seem to be doing much good except frustrating people more when their apps throw (#6895, FB-internal t11950821). Until more proper error boundaries land, let's make this a warning.
(cherry picked from commit abcd567)
mrizwanashiq pushed a commit to mrizwanashiq/react that referenced this pull request Jun 25, 2026
This was added to catch internal errors in React but doesn't seem to be doing much good except frustrating people more when their apps throw (react#6895, FB-internal t11950821). Until more proper error boundaries land, let's make this a warning.
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.

4 participants