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

THREAD_SUBPROCS=None for xonshrc files #3705

Merged
merged 1 commit into from Aug 22, 2020
Merged

THREAD_SUBPROCS=None for xonshrc files #3705

merged 1 commit into from Aug 22, 2020

Conversation

scopatz
Copy link
Member

@scopatz scopatz commented Aug 21, 2020

This is related to the issue at regro/rever#217. I independently verified that even xonsh itself was having trouble starting up if any threaded subproc was used in rc files. Super weird and hard to diagnose. The issue seems to have first arrived in the environment refactor (a8d4a57), but seems to be a side effect of that commit rather than directly caused by it.

@scopatz
Copy link
Member Author

scopatz commented Aug 21, 2020

@xonsh/xore - this is ready for review!

@hadim
Copy link

hadim commented Aug 22, 2020

I confirm this PR works for me on Ubuntu 20.04 (I am using it only to run rever).

@scopatz
Copy link
Member Author

scopatz commented Aug 22, 2020

Pinging this again @xonsh/xore

@laloch
Copy link
Member

laloch commented Aug 22, 2020

@scopatz, I hear you. To be completely honest, I don't agree with the change, because it breaks the expected behavior on POSIX. On the other hand it enables job control and removes a lot of confusion about threaded/unthreaded behavior. I would very much like to see a follow-up commit with a documentation change describing thoroughly the effects of the $THREAD_SUBPROCS switch.
I realize, that you are currently pushing towards v1.0, so yes, let's do this, but please, don't forget that this is evil and that we want to find a way to make all our subprocesses reliably threadable.

@laloch laloch merged commit eb73899 into master Aug 22, 2020
@scopatz
Copy link
Member Author

scopatz commented Aug 22, 2020

Yeah, to be clear I totally agree about wanting to make the sub-processes reliably threadable. Also this doesn't change the default behavior in any way once xonsh is loaded. (ie THREAD_SUBPROCS=True still) This only turns of threadable supbrocs temporarily while xonsh is loading so that you can reliably start xonsh from Bash. Do you still think this needs more docs than I added here?

@scopatz scopatz deleted the nothreadrc branch August 22, 2020 23:56
@scopatz
Copy link
Member Author

scopatz commented Aug 22, 2020

Also, thanks for the merge!

@laloch
Copy link
Member

laloch commented Aug 23, 2020

Thanks for the PR!

Do you still think this needs more docs than I added here?

Yes, I do. We need to point out, that the RC scripts may behave differently from the regular code and why.

@scopatz
Copy link
Member Author

scopatz commented Aug 23, 2020

Ahh Ok I will put it in

@scopatz
Copy link
Member Author

scopatz commented Aug 23, 2020

done in #3708

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.

None yet

3 participants