Skip to content

Commit

Permalink
Remove workaround for macOS failing to launch process with materializ…
Browse files Browse the repository at this point in the history
…ed argv0 (pantsbuild#12095)

Closes pantsbuild#11406.

[ci skip-build-wheels]
  • Loading branch information
Eric-Arellano authored May 20, 2021
1 parent 5b111c8 commit 613f0b6
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions src/rust/engine/process_execution/src/local.rs
Original file line number Diff line number Diff line change
Expand Up @@ -295,13 +295,7 @@ impl CapturedWorkdir for CommandRunner {
} else {
workdir_path.to_owned()
};
// TODO(#11406): Go back to using relative paths, rather than absolutifying them, once Rust
// fixes https://github.com/rust-lang/rust/issues/80819 for macOS.
let argv0 = match RelativePath::new(&req.argv[0]) {
Ok(rel_path) => cwd.join(rel_path),
Err(_) => PathBuf::from(&req.argv[0]),
};
let mut command = HermeticCommand::new(argv0);
let mut command = HermeticCommand::new(&req.argv[0]);
command.args(&req.argv[1..]).current_dir(cwd).envs(&req.env);

// See the documentation of the `CapturedWorkdir::run_in_workdir` method, but `exclusive_spawn`
Expand Down

0 comments on commit 613f0b6

Please sign in to comment.