Repository navigation
Conversation
With one worker, files that inherit an open act() scope now name an act() call that was not awaited when no test in the leaving file failed while the scope was open, instead of describing it as a likely timeout.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
With one worker under
hotRuntime, files that inherit an openact()scope now say when the cause is anact()call that was not awaited, instead of describing every open scope as a likely timeout.Why
An un-awaited async
act()never closes React's scope. TheHOT_RESIDENT_UNUSABLEmessage blamed a timeout, which sent users looking for the wrong bug.Changes
act()call in that file that was not awaited and says to await it. Otherwise it keeps the timeout wording.test:native:hot:act-scopeadds a one-worker un-awaited case. Both one-worker cases now check which cause they name.errors.mdand the troubleshooting Known differences entry describe both causes.Notes
act()result was awaited is private to React, so a scope that will never close can't be told apart from one still waiting on its callback without wrappingact().Fixes #812