Skip to content

Validate health_check_interval_min at config load #92

Description

@mayankpande88

The health_check_interval_min value (pkg/config/config.go:21) is passed straight to the WebSocket client (cmd/app.go:59). A zero or negative value is silently accepted and produces broken timer behavior at runtime.

Proposed scope

  • In config.Load, reject health_check_interval_min < 1 with a clear error, following the same pattern used for the required access_key / access_secret checks.

Acceptance criteria

  • Unit test in pkg/config/config_test.go covering negative, zero, and valid values.
  • Error message is descriptive.

Pointers

  • pkg/config/config.go:21 (field), :88 (default), :135-140 (existing required-field error pattern)
  • cmd/app.go:59 (consumer)

Good first issue: minimal, isolated validation.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestgoPull requests that update go codegood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions