atc0005/check-statuspage

CRITICAL: Error initializing application | failed to set flags configuration: flag: help requested

Closed this issue · 2 comments

Output from the plugin when using the help flag:

$ ./release_assets/check_statuspage_components/check_statuspage_components-66c96c4-linux-amd64 --help

check-statuspage 66c96c4 (https://github.com/atc0005/check-statuspage)

Usage of ./release_assets/check_statuspage_components/check_statuspage_components-66c96c4-linux-amd64:
  -allow-unknown-fields
        Whether unknown JSON fields encountered while decoding JSON data should be ignored.
  -auf
        Whether unknown JSON fields encountered while decoding JSON data should be ignored. (shorthand)
  -branding
        Toggles emission of branding details with plugin status details. This output is disabled by default.
  -c value
        One or more comma-separated component (name or ID) values. Can be used by itself or with the flag to specify a component group. If used with the component group flag, all specified components are required to be subcomponents of the group. (shorthand)
  -component value
        One or more comma-separated component (name or ID) values. Can be used by itself or with the flag to specify a component group. If used with the component group flag, all specified components are required to be subcomponents of the group.
  -ea
        Whether all components should be evaluated. Incompatible with flag to specify list of components, component group or component group set. (shorthand)
  -eval-all
        Whether all components should be evaluated. Incompatible with flag to specify list of components, component group or component group set.
  -f string
        The fully-qualified filename of a previously downloaded Statuspage API/JSON feed (e.g., /tmp/statuspage/github/components.json). (shorthand)
  -filename string
        The fully-qualified filename of a previously downloaded Statuspage API/JSON feed (e.g., /tmp/statuspage/github/components.json).
  -g string
        A single name or ID value for a component group. Can be used by itself or with the flag to specify a list of components. If used with the components flag all specified components are required to be subcomponents of the group. (shorthand)
  -group string
        A single name or ID value for a component group. Can be used by itself or with the flag to specify a list of components. If used with the components flag all specified components are required to be subcomponents of the group.
  -ll string
        Sets log level to one of disabled, panic, fatal, error, warn, info, debug or trace. (shorthand) (default "info")
  -log-level string
        Sets log level to one of disabled, panic, fatal, error, warn, info, debug or trace. (default "info")
  -omit-ok
        Whether listed components in results output should be limited to just those in a non-operational state. Does not apply to all output formats.
  -ook
        Whether listed components in results output should be limited to just those in a non-operational state. Does not apply to all output formats. (shorthand)
  -read-limit int
        Limit in bytes used to help prevent abuse when reading input that could be larger than expected. The default value is nearly 4x the largest observed (formatted) feed size. (default 1048576)
  -rl int
        Limit in bytes used to help prevent abuse when reading input that could be larger than expected. The default value is nearly 4x the largest observed (formatted) feed size. (shorthand) (default 1048576)
  -t int
        Timeout value in seconds allowed before an execution attempt is abandoned and an error returned. (shorthand) (default 10)
  -timeout int
        Timeout value in seconds allowed before an execution attempt is abandoned and an error returned. (default 10)
  -u string
        The fully-qualified URL of a Statuspage API/JSON feed (e.g., https://www.githubstatus.com/api/v2/components.json). (shorthand)
  -url string
        The fully-qualified URL of a Statuspage API/JSON feed (e.g., https://www.githubstatus.com/api/v2/components.json).
  -v    Whether to display application version and then immediately exit application. (shorthand)
  -version
        Whether to display application version and then immediately exit application.
{"level":"error","error":"failed to set flags configuration: flag: help requested","time":"2021-12-27T05:51:28-06:00","message":"Error initializing application"}
CRITICAL: Error initializing application

**ERRORS**

* failed to set flags configuration: flag: help requested
 | 'time'=2ms;;;;

From the lscs binary:

$ ./release_assets/lscs/lscs-66c96c4-linux-amd64 --help

check-statuspage 66c96c4 (https://github.com/atc0005/check-statuspage)

Usage of ./release_assets/lscs/lscs-66c96c4-linux-amd64:
  -allow-unknown-fields
        Whether unknown JSON fields encountered while decoding JSON data should be ignored.
  -auf
        Whether unknown JSON fields encountered while decoding JSON data should be ignored. (shorthand)
  -f string
        The fully-qualified filename of a previously downloaded Statuspage API/JSON feed (e.g., /tmp/statuspage/github/components.json). (shorthand)
  -filename string
        The fully-qualified filename of a previously downloaded Statuspage API/JSON feed (e.g., /tmp/statuspage/github/components.json).
  -fmt string
        Sets output format to one of overview, table, verbose, debug, list or json. (shorthand) (default "table")
  -ll string
        Sets log level to one of disabled, panic, fatal, error, warn, info, debug or trace. (shorthand) (default "info")
  -log-level string
        Sets log level to one of disabled, panic, fatal, error, warn, info, debug or trace. (default "info")
  -omit-ok
        Whether listed components in results output should be limited to just those in a non-operational state. Does not apply to all output formats.
  -ook
        Whether listed components in results output should be limited to just those in a non-operational state. Does not apply to all output formats. (shorthand)
  -output-format string
        Sets output format to one of overview, table, verbose, debug, list or json. (default "table")
  -read-limit int
        Limit in bytes used to help prevent abuse when reading input that could be larger than expected. The default value is nearly 4x the largest observed (formatted) feed size. (default 1048576)
  -rl int
        Limit in bytes used to help prevent abuse when reading input that could be larger than expected. The default value is nearly 4x the largest observed (formatted) feed size. (shorthand) (default 1048576)
  -t int
        Timeout value in seconds allowed before an execution attempt is abandoned and an error returned. (shorthand) (default 10)
  -timeout int
        Timeout value in seconds allowed before an execution attempt is abandoned and an error returned. (default 10)
  -u string
        The fully-qualified URL of a Statuspage API/JSON feed (e.g., https://www.githubstatus.com/api/v2/components.json). (shorthand)
  -url string
        The fully-qualified URL of a Statuspage API/JSON feed (e.g., https://www.githubstatus.com/api/v2/components.json).
  -v    Whether to display application version and then immediately exit application. (shorthand)
  -version
        Whether to display application version and then immediately exit application.
{"level":"error","error":"failed to set flags configuration: flag: help requested","time":"2021-12-27T05:53:32-06:00","message":"Error initializing application"}

Evidently this slipped in when I adjusted flag handling while working on implementing tests.

#25 resolved the error, but did not actually restore the help output as intended.