You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description:
Currently when applying a custom ruleset to woke (local or remote), there is no validation on the ruleset and various cases where rulesets silently "die" and are not applied to the final ruleset. The developer/user is not notified that their ruleset was not applied (or errored out while configuring), nor does it suggest to the developer/user why their ruleset was not applied.
For example, if the applied ruleset yaml contains just "hello" --> we get the error:
FTL error="yaml: unmarshal errors:\n line 1: cannot unmarshal !!str hello into config.Config"
exit status 1
However, another ruleset yaml containing: "rules: man" --> there is no error.
yaml: unmarshal believes it is a valid yaml in general, but woke does not see it as a valid rule set. Woke doesn't add the custom rules to the final ruleset. The ruleset silently "dies" and no errors are logged to the user.
Acceptance Criteria:
Post issue on get-woke/woke repo to get maintainer input on design & implementation and update description based on feedback
Enhance error handling for applying custom rulesets for cases that silently die
(Stretch) Implement adding a schema validator to validate the applied ruleset yaml. The validator should parse the yaml looking for the correct ruleset yaml structure and log out any errors with your ruleset (as opposed to silently dying and not applying rules which is the current state).
The text was updated successfully, but these errors were encountered:
mkcomer
changed the title
Add a schema validator for parsing a custom ruleset and enable custom error logging
Add validation for custom ruleset and error logging
Oct 13, 2021
mkcomer
changed the title
Add validation for custom ruleset and error logging
Add validation to custom rulesets (remote and local) and enhance error logging
Oct 13, 2021
mkcomer
changed the title
Add validation to custom rulesets (remote and local) and enhance error logging
Enhance config error logging and add validation to custom rulesets (remote and local) and
Oct 13, 2021
mkcomer
changed the title
Enhance config error logging and add validation to custom rulesets (remote and local) and
Enhance config error logging and add validation to custom rulesets (remote and local)
Oct 13, 2021
Description:
Currently when applying a custom ruleset to woke (local or remote), there is no validation on the ruleset and various cases where rulesets silently "die" and are not applied to the final ruleset. The developer/user is not notified that their ruleset was not applied (or errored out while configuring), nor does it suggest to the developer/user why their ruleset was not applied.
For example, if the applied ruleset yaml contains just "hello" --> we get the error:
FTL error="yaml: unmarshal errors:\n line 1: cannot unmarshal !!str hello into config.Config"
exit status 1
However, another ruleset yaml containing: "rules: man" --> there is no error.
yaml: unmarshal believes it is a valid yaml in general, but woke does not see it as a valid rule set. Woke doesn't add the custom rules to the final ruleset. The ruleset silently "dies" and no errors are logged to the user.
Acceptance Criteria:
get-woke/woke
repo to get maintainer input on design & implementation and update description based on feedbackThe text was updated successfully, but these errors were encountered: