Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ require (
go.opentelemetry.io/proto/otlp v1.10.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
go.uber.org/zap v1.27.1 // indirect
go.yaml.in/yaml/v2 v2.4.2 // indirect
go.yaml.in/yaml/v3 v3.0.4 // indirect
go.yaml.in/yaml/v3 v3.0.4 // indirect
Comment on lines +128 to 129
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major | ⚑ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify duplicate module entries in go.mod require blocks.
awk '
  BEGIN { inreq=0 }
  /^\s*require\s*\(/ { inreq=1; next }
  inreq && /^\s*\)/ { inreq=0; next }
  inreq {
    # capture "<module> <version>" lines, optional "// indirect"
    if (match($0, /^[[:space:]]*([[:graph:]]+)[[:space:]]+([[:graph:]]+)/, m)) {
      key=m[1]
      cnt[key]++
      lines[key]=lines[key] "NR " NR ": " $0 "\n"
    }
  }
  END {
    dup=0
    for (k in cnt) {
      if (cnt[k] > 1) {
        dup=1
        printf "Duplicate require entry for %s (%d occurrences):\n%s\n", k, cnt[k], lines[k]
      }
    }
    if (dup==0) print "No duplicate require entries found."
  }
' go.mod

Repository: openshift-hyperfleet/hyperfleet-sentinel

Length of output: 243


Remove the duplicate go.yaml.in/yaml/v3 requirement.

Lines 128 and 129 both declare go.yaml.in/yaml/v3 v3.0.4 // indirect. Keep a single entry to avoid dependency metadata inconsistencies and potential friction with go mod tidy.

πŸ€– Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@go.mod` around lines 128 - 129, Remove the duplicate dependency entry for
"go.yaml.in/yaml/v3 v3.0.4 // indirect" in go.mod so only a single line remains;
locate the two identical lines declaring go.yaml.in/yaml/v3 and delete one of
them, then run "go mod tidy" to reconcile module metadata.

golang.org/x/crypto v0.49.0 // indirect
golang.org/x/net v0.52.0 // indirect
Expand Down