chore: fix dependabot alerts - #4441
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4441 +/- ##
==========================================
+ Coverage 92.01% 94.59% +2.58%
==========================================
Files 215 215
Lines 33058 29839 -3219
==========================================
- Hits 30419 28227 -2192
+ Misses 1682 1612 -70
+ Partials 957 0 -957 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Signed-off-by: Ramkumar Chinchani <rchincha.dev@gmail.com>
Contributor
|
Please fix lint issues. |
Signed-off-by: Ramkumar Chinchani <rchincha.dev@gmail.com>
Replace errors.As(err, &x) with the generic errors.AsType[T](err), and flatten embedded-field composite literals now that Go 1.27 allows initializing promoted fields directly, closing out the modernize findings golangci-lint's max-same-issues cap was hiding. Signed-off-by: Ramkumar Chinchani <rchincha.dev@gmail.com>
Signed-off-by: Ramkumar Chinchani <rchincha.dev@gmail.com>
vrajashkr
approved these changes
Sep 19, 2026
vrajashkr
left a comment
Contributor
There was a problem hiding this comment.
LGTM. Left one question.
| func getSubjectFromCosignTag(tag string) godigest.Digest { | ||
| alg := strings.Split(tag, "-")[0] | ||
| encoded := strings.Split(tag, "-")[1] | ||
| alg, encoded, _ := strings.Cut(tag, "-") |
Contributor
There was a problem hiding this comment.
Is it guaranteed that the tag that will come here is validated to be in the right format?
strings.Cut returns before, after, and found. In case the tag has 2 hyphens in it, the "after" will be invalid.
If the tag is validated/always generated by code, then no problems here.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What type of PR is this?
Which issue does this PR fix:
What does this PR do / Why do we need it:
If an issue # is not available please add repro steps and logs showing the issue:
Testing done on this change:
Automation added to e2e:
Will this break upgrades or downgrades?
Does this PR introduce any user-facing change?:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.