-
Notifications
You must be signed in to change notification settings - Fork 64
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
fix: showing verifier config parse detail in err log #1791
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
|
Just curious, why are there 2 different |
I guess the second error wraps the first one(nested one) but we logged both. |
pkg/verifier/notation/notation.go
Outdated
logger.GetLogger(context.Background(), logOpt).Error("Get VerificationCertStores in mixed format") | ||
return re.ErrorCodeConfigInvalid.WithDetail("The verificationCertStores is misconfigured with both legacy and new formats").WithRemediation("Please provide only one format for the VerificationCertStores. Refer to the Notation Verifier configuration guide: https://ratify.dev/docs/plugins/verifier/notation#configuration") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logger.GetLogger(context.Background(), logOpt).Error("Get VerificationCertStores in mixed format") | |
return re.ErrorCodeConfigInvalid.WithDetail("The verificationCertStores is misconfigured with both legacy and new formats").WithRemediation("Please provide only one format for the VerificationCertStores. Refer to the Notation Verifier configuration guide: https://ratify.dev/docs/plugins/verifier/notation#configuration") | |
err := re.ErrorCodeConfigInvalid.WithDetail("The verificationCertStores is misconfigured with both legacy and new formats: %+v", conf).WithRemediation("Please provide only one format for the VerificationCertStores. Refer to the Notation Verifier configuration guide: https://ratify.dev/docs/plugins/verifier/notation#configuration") | |
logger.GetLogger(context.Background(), logOpt).Error(err) | |
return err |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated.
Found similar issue been raised to the markdown link checker: tcort/markdown-link-check#349
|
…1791) Signed-off-by: akashsinghal <[email protected]>
Description
What this PR does / why we need it:
Which issue(s) this PR fixes (optional, using
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when the PR gets merged):Showing verifier config parse error about using
VerificationCertStores
in mixed format in err logType of change
Please delete options that are not relevant.
Before:
Screen Capture
Details
After:
Screen Capture
Details
How Has This Been Tested?
-[x] AKS test in my own fork.
ref: https://github.com/junczhu/ratify/actions/runs/10789084563/job/29921271326?pr=22
Checklist:
Post Merge Requirements
Helm Chart Change