Skip to content

Commit

Permalink
More robust artifact library loading
Browse files Browse the repository at this point in the history
  • Loading branch information
pxl-th committed Oct 17, 2024
1 parent 0905cc8 commit 1dfb8c1
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/discovery/utils.jl
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,14 @@ end
function safe_exec(str)
cmd = julia_cmd_projects(str)
success = false
error_str = mktemp() do path, _
p = run(pipeline(cmd; stdout=path, stderr=path); wait=false)
res_str, err_str = mktemp() do path, _
p = run(pipeline(cmd; stdout=path, stderr="$path.err"); wait=false)
wait(p)
success = p.exitcode == 0
strip(String(read(path)))
res_str = strip(String(read(path)))
err_str = strip(String(read("$path.err")))
end
return success, error_str
return success, res_str
end

"""
Expand Down

0 comments on commit 1dfb8c1

Please sign in to comment.