Skip to content

v0.9.2

@nshkrdotcom nshkrdotcom tagged this 28 Jan 20:48
Fixed `run_command_with_timeout/2` passing `{:timeout, ms}` inside the
options list to `:exec.run/2`, which does not accept that tuple as an
option. This caused `:exec.run` to return
`{:error, {:invalid_option, {:timeout, 30000}}}`, making
`authenticated?/0` return `false` even when the CLI is installed and
authenticated. The fix switches to `:exec.run/3` with the timeout as a
separate third argument.

Bug Fix:

- Replace `:exec.run(command, [:sync, :stdout, :stderr, {:timeout, ms}])`
with `:exec.run(command, [:sync, :stdout, :stderr], timeout_ms)` in
AuthChecker.run_command_with_timeout/2.

Testing:

- Add AuthCheckerExecTimeoutTest regression test verifying the erlexec
call pattern does not produce `{:error, {:invalid_option, _}}`.
Assets 2
Loading