[hermes] metis: go:S3776 #4
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
SonarQube reports go:S3776 in
pkg/sentinel/collector.go. The build is green; this is a standing finding, not a failure.What is wrong
The cognitive complexity is mainly due to nested conditionals and loops inside collectUSBScratch, especially the bind‑target health checks and the multiple device resolution steps.
Ariadne opened no pull request for it: no automated patch was possible for this finding.
Facts
pkg/sentinel/collector.go:131)Suggested fix (not applied)
Hermes could not open a pull request for this, so the change below was not written, validated, or pushed anywhere. It is a starting point for whoever picks this up, not a reviewed patch.
pkg/sentinel/collector.go— Extract the bind‑target health loop and related state updates into a helper function to flatten collectUSBScratch. This reduces nesting and keeps the original logic intact.Links
/api/admin/audit/events, event typeshermes_autotriage_incidentandhermes_autotriage_diagnosis.Filed automatically by Ariadne from a Hermes Agent diagnosis (run run_213c42165ee74502b1b579125e93d9c8). Hermes has no write access to this repository; no files or infrastructure were changed.