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

Reduce scope of Runtime.block_on #8155

Merged

Conversation

@illicitonion
Copy link
Contributor

commented Aug 9, 2019

Assertions in the Future context end up panicking a background thread,
which means we don't necessarily flush stdout buffers, and the error
message we get is more along the lines of "Future cancelled" rather than
a useful assertion error.

Instead, only block on the Futuresy piece, and perform assertions on the
main test thread.

Reduce scope of Runtime.block_on
Assertions in the Future context end up panicking a background thread,
which means we don't necessarily flush stdout buffers, and the error
message we get is more along the lines of "Future cancelled" rather than
a useful assertion error.

Instead, only block on the Futuresy piece, and perform assertions on the
main test thread.

@illicitonion illicitonion force-pushed the twitter:dwagnerhall/deflaking/block_on_less branch from 415adcc to afa1a54 Aug 12, 2019

@illicitonion illicitonion merged commit 1a7f126 into pantsbuild:master Aug 12, 2019

@illicitonion illicitonion deleted the twitter:dwagnerhall/deflaking/block_on_less branch Aug 12, 2019

@stuhood stuhood added this to the 1.19.x milestone Aug 22, 2019

stuhood added a commit that referenced this pull request Aug 22, 2019
Reduce scope of Runtime.block_on (#8155)
Assertions in the Future context end up panicking a background thread,
which means we don't necessarily flush stdout buffers, and the error
message we get is more along the lines of "Future cancelled" rather than
a useful assertion error.

Instead, only block on the Futuresy piece, and perform assertions on the
main test thread.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.