-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Labels
Description
osproc
always seems to output an error message relating to the binary being executed rather than an actual reason.
Example
import std/osproc
discard execCmdEx("echo", workingDir = "not-a-dir")
Actual Output
/home/chronos/test/main.nim(3) main
/home/chronos/.nimskull/lib/pure/osproc.nim(1637) execCmdEx
/home/chronos/.nimskull/lib/pure/osproc.nim(1045) startProcess
/home/chronos/.nimskull/lib/pure/osproc.nim(1155) startProcessAuxFork
/home/chronos/.nimskull/lib/pure/includes/oserr.nim(95) raiseOSError
Error: unhandled exception: Additional info: Could not find command: '/bin/sh'. OS error: No such file or directory [OSError]
Expected Output
Something about the directory not existing and that being the cause of the execution not happening.
Possible Solution
Most likely, just some sanity checks like if the working directory exists.