Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Discrepancy in Validation Failure Output #1047

Closed
mikeradka opened this issue Apr 17, 2024 · 2 comments
Closed

Discrepancy in Validation Failure Output #1047

mikeradka opened this issue Apr 17, 2024 · 2 comments
Assignees

Comments

@mikeradka
Copy link
Contributor

mikeradka commented Apr 17, 2024

I encountered a Schema Validation issue with our Github Actions. Despite repeatedly receiving the message FAILED: Required keys are present, the validation problem stemmed from a missing attribute in the dictionary. Upon adding the attribute, the failure message ceased. Could we explore enhancing the output of our validation process? With the discrepancy in messaging, there were recurrent validation failures without a clear path to resolution, as the message implied a required field needed fixing.

image
@mikeradka mikeradka added bug Something isn't working and removed bug Something isn't working labels Apr 17, 2024
@alanisaac
Copy link
Contributor

alanisaac commented Apr 18, 2024

There is also an earlier error in the GitHub action run above here:

TESTING: Required keys are present
   ERROR: Missing required key `OcsfAttr.caption` at `attributes.log_file` in events/system/event_log.json

But that error also does not point out how to resolve it.

Enhancements we could make:

  • Provide resolutions for any error where a common resolution is known.
  • Only summarize errors (not passes) on failure, and include the error messages to make them more obvious. That would be a similar pattern to how many code testing frameworks work, for example.
  • (nice to have): colorize output in GitHub actions to make all messages (errors, warnings, etc.) in the log more prominent and easier to scan

@alanisaac
Copy link
Contributor

I'm going to leave the second bullet alone for now, and close this as is. The other two bullets have been implemented, and should help with both making the error more prominent and the resolution more clear.

@alanisaac alanisaac self-assigned this May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants