Skip to content

error handling need when no value provided for "output format" #546

@gregorybrzeski

Description

@gregorybrzeski

Running of h1-cli without a value for --output / -o needs better error handling.

Preferably information that values is missing or is not from allowed set of options. Would be nice if possible options were shown in error message as well like in --help.

$ ./h1 iam project list -o 
TypeError: formatter is not a function
    at Object.opts.format (webpack:///../cli-core/plugin/formatOutput.js?:95:20)
    at Command.handler (webpack:////home/runner/work/h1-cli/h1-cli/extensions/cli-ext-root-openapi-generator/index.js?:95:25)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions