Repository navigation
Conversation
1 of 6 tasks
mattip
commented
Jun 7, 2022
| setup_worker_path=os.path.join( | ||
| os.path.dirname(os.path.abspath(__file__)), | ||
| f"workers/{ray_constants.SETUP_WORKER_FILENAME}", | ||
| "workers", f"{ray_constants.SETUP_WORKER_FILENAME}", |
Contributor
Author
There was a problem hiding this comment.
This fixes the / for windows by using os.path.join with multiple arguments. The previous code worked, but looks strange in debug logs
mattip
commented
Jun 7, 2022
| if child_pid == 0: | ||
| # child process | ||
| os.execvp("bash", ["bash", "-c", command_str]) | ||
| subprocess.run(command_args) |
Contributor
Author
There was a problem hiding this comment.
Make this work as it does in the unmocked code
Contributor
|
@pcmoritz could you pass this on for review by the Ray/windows experts |
mattip
marked this pull request as draft
June 12, 2022 08:39
1 of 6 tasks
Contributor
Author
|
Closing. Replaced by #25659 |
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.
Why are these changes needed?
The call to
os.execvpfor starting a worker process is complicated and can be replaced withsubprocess.run. This will also solve the problem of paths with spaces in them, since subprocess properly handles them.Related issue number
Closes #24574
Replaces #25151
Checks
scripts/format.shto lint the changes in this PR.