st2-register-content fails with unclear error messages if --config-file is not supplied.
Open
Nobody has claimed this yet.
complexity:medium
enhancement
- Dominant language
- Python
- Stars
- 6.5k
- Forks
- 787
- PR merge metrics
- No merged PRs in 30d
Description
Reported by: @code-ape
Currently, st2-register-content uses oslo and we require --config-file for things like logging config, db location etc. If --config-file option is not supplied, we try to go with the defaults and this pretty much blows up when people use custom installations.
- We should fail fast on --config-file option not being set. (We have to find a way to introduce a logging config that's default and not rely on config-file for log config location)
- We should really think about fail fast on first error as default option
- We should improve the UX for this CLI tool.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the st2-register-content CLI entry point and reproduce the failure without --config-file. Read the oslo configuration and logging setup to determine how missing configuration is handled; done should include a clear fail-fast error and verified behavior for the requested CLI error-handling improvements.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli, devops
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100