Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: turn on event validation by default (#562)
* feat: turn on event validation by default * fix: clap is weirs with bools, we need to parse them and explicitly define an action on them to set them * fix: use option in event_validation flag * chore: add comment and set default_value to true, using default_value_t=Some(true) will break the code. The default_value_t cannot be used here : The default_value_t attribute in Clap requires the type to implement Display because it needs to be able to print the default value in the help text. However, Option<T> does not implement Display, even if T does. To work around this, we use default_value instead This works because Clap will parse the string true into a bool and then wrap it in Some(...). We have additionally also handled this in the code parsing using an unwrap_or(). The default_value is added more for semantic purposes to aid readability of the code --------- Co-authored-by: Samika Kashyap <[email protected]>
- Loading branch information