Concordium / Concordium/concordium-node
Upgrade to clap 4.0 to improve the node command-line flags
- Dominant language
- Haskell
- Stars
- 108
- Forks
- 24
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 9
Description
**Description**
Currently the node expects a value for the value of command-line switches, e.g., the switch `--no-bootstrap` cannot be supplied as such, and needs to be given either as `--no-bootstrap=` or `--no-bootstrap=true`. In fact any value is equivalent, including `--no-bootstrap=false` will set the `no-bootstrap` switch.
The reason for this is the limitation of clap 2.* versions where if the environment variable is used the flag must take a value.
Clap 3.0 was just released https://epage.github.io/blog/2021/12/clap3/ which removes this limitation (see https://github.com/clap-rs/clap/issues/1476 ) and it would be useful to upgrade to that to improve the command-line interface of the node.
This will change the command-line interface of the node slightly but with the major node release it should be acceptable to change to improve.
Contributor guide
Research direction
Start by locating the node's command-line argument definitions, dependency configuration, and any tests covering environment-backed flags. Verify the current behavior of --no-bootstrap and related switches, then confirm that the upgrade permits bare boolean flags while preserving environment-variable support and expected CLI behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100