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

Fix bugs/race conditions in shell #1124

Merged
merged 1 commit into from
Mar 19, 2016

Conversation

ferd
Copy link
Collaborator

@ferd ferd commented Mar 19, 2016

Following suggestions from @psyeugenic, this code terminates and waits
for the termination of the port handling IO before booting our own,
which should get rid of annoying warnings.

We also allow for the failure to shutdown the user worker under
kernel_sup, since it is likely not there anymore in many scenarios,
preventing crashes.

Tested on linux and OSX under escript and local install, with and without TERM=dumb. Windows testing still required.

Should fix #1028

Following suggestions from @psyeugenic, this code terminates and waits
for the termination of the port handling IO before booting our own,
which should get rid of annoying warnings.

We also allow for the failure to shutdown the user worker under
kernel_sup, since it is likely not there anymore in many scenarios,
preventing crashes.
@ferd ferd changed the title Fix bugs/race conditions Fix bugs/race conditions in shell Mar 19, 2016
@psyeugenic
Copy link
Contributor

👍

@shaneutt
Copy link

I used this rebar in the same way that I have previously [that got the bad behavior in #1028] on a project that was having this issue about every 1 in 10 tries.

After 100 shell runs I did not receive the error.

It's not conclusive because the error was not consistently reproducible, but given a large number of attempts it looks to be working as intended.

I did not encounter any other issues with rebar while testing this.

tsloughter added a commit that referenced this pull request Mar 19, 2016
@tsloughter tsloughter merged commit 4e81c84 into erlang:master Mar 19, 2016
@ferd ferd deleted the improve-intermittent-shell-issues branch March 19, 2016 18:16
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 this pull request may close these issues.

intermittent ./rebar3 shell issues with nightly
4 participants