Skip to content

Discuss alternatives for getRelayUptimeSeconds error handling #590

@CKodidela

Description

@CKodidela

Context

In #585 , getRelayUptimeSeconds was patched to wrap
runCommandWithOutput in a try/catch to handle the case where
Docker is not installed. When Docker is missing, spawn emits
an ENOENT error instead of returning a non-zero exit code, which
was causing info --json to crash and break the pre-commit hook.

Problem

The current fix works but is a short-term solution. We should
discuss better long-term alternatives.

Potential Alternatives

  • Pre-check if Docker is installed before invoking the command
  • TBD

Goal

Agree on a consistent approach so similar issues don't arise in
other command wrappers.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions