-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
[WIP] Check license files in CI #6342
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Not sure what's going on, but for me |
// the caller knows no overflow occurred. | ||
func SafeParseInt(in interface{}) (int, error) { | ||
raw, err := SafeParseIntRange(in, math.MinInt, math.MaxInt) | ||
return int(raw), err |
Check failure
Code scanning / CodeQL
Incorrect conversion between integer types
|
||
var result = make([]int, 0, len(raw)) | ||
for _, element := range raw { | ||
result = append(result, int(element)) |
Check failure
Code scanning / CodeQL
Incorrect conversion between integer types
remainingIfAddrs := make(IfAddrs, 0, len(ifAddrs)) | ||
|
||
rfcNetMap := KnownRFCs() | ||
rfcNets, ok := rfcNetMap[uint(inputRFC)] |
Check failure
Code scanning / CodeQL
Incorrect conversion between integer types
return IfAddrs{}, IfAddrs{}, fmt.Errorf("mask size out of bounds for IPv6 address: %d", maskSize) | ||
} | ||
|
||
if (*ipAddr).Maskbits() == int(maskSize) { |
Check failure
Code scanning / CodeQL
Incorrect conversion between integer types
|
||
ipv4 := *ToIPv4Addr(inputIfAddr.SockAddr) | ||
ipv4Uint32 := uint32(ipv4.Address) | ||
ipv4Uint32 += uint32(i) |
Check failure
Code scanning / CodeQL
Incorrect conversion between integer types
wrappedMask = 1 + i + int64(^uint32(ipv4.Mask)) | ||
} | ||
|
||
ipv4Uint32 = ipv4Uint32 + (uint32(wrappedMask) &^ uint32(ipv4.Mask)) |
Check failure
Code scanning / CodeQL
Incorrect conversion between integer types
This commit updates verify-codegen.sh to verify that licenses have been updated. It also saves local state for go.mod and go.sum during verification, since hack/update-codegen.sh (via hack/update-deps.sh) may modify these files. This ensures that code is modified only by hack/update-codegen.sh and not hack/verify-codegen.sh. Lastly, it updates the version of go-licenses used in hack/update-deps.sh and re-runs codegen.
Going to go with the approach of removing third_party instead, based on conversation in #6015 |
Changes
This commit updates verify-codegen.sh to verify that licenses have been updated.
It also saves local state for go.mod and go.sum during verification, since
hack/update-codegen.sh (via hack/update-deps.sh) may modify these files.
This ensures that code is modified only by hack/update-codegen.sh and not hack/verify-codegen.sh.
/kind misc
Closes #6210
Closes #6352
Submitter Checklist
As the author of this PR, please check off the items in this checklist:
functionality, content, code)
/kind <type>
. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tepRelease Notes