Skip to content

Commit

Permalink
drop cmd_string
Browse files Browse the repository at this point in the history
  • Loading branch information
sorhawell committed Jul 18, 2023
1 parent 0694664 commit 4ef435e
Showing 1 changed file with 8 additions and 12 deletions.
20 changes: 8 additions & 12 deletions src/rust/src/rbackground.rs
Original file line number Diff line number Diff line change
Expand Up @@ -209,22 +209,18 @@ impl RBackgroundHandler {
let (server, server_name) = ipc::IpcOneShotServer::new()
.when("trying to create a one-shot channel to setup inter-process communication")?;

let cmd_string = format!(
"R --vanilla -q -e 'invisible(polars:::handle_background_request(\"{server_name}\"))'"
);
let child = Command::new(cmd_string)
// .arg("--vanilla")
// .arg("-q")
// .arg("-e")
// // Remove rextendr::document() if possible
// .arg(format!(
// "'invisible(polars:::handle_background_request(\"{server_name}\"))'"
// ))
let child = Command::new("R")
.arg("--vanilla")
.arg("-q")
.arg("-e")
// Remove rextendr::document() if possible
.arg(format!(
"invisible(polars:::handle_background_request(\"{server_name}\"))"
))
.stdin(Stdio::null())
.stdout(Stdio::null())
.stderr(Stdio::null())
.spawn()
.plain(cmd_string)
.when("trying to spawn a background R process")?;
let (_, tx): (_, ipc::IpcSender<RIPCJob>) = server
.accept()
Expand Down

0 comments on commit 4ef435e

Please sign in to comment.