[hermes] ariadne: python:S2208 #134
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 python:S2208 in
ariadne/services/cluster_state_profiles.py. The build is green; this is a standing finding, not a failure.What is wrong
Line 5 uses a wildcard import (
from .cluster_state_contract import *), which hides which names the module actually depends on. The file only uses four imported names:_NODE_WORKLOAD_TOP,_PROFILE_LIMIT, and (via the dynamic__all__computation overglobals())ClusterStateSummaryandSignalContext.Ariadne opened no pull request for it: no automated patch was possible for this finding.
Facts
ariadne/services/cluster_state_profiles.py:5)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.
ariadne/services/cluster_state_profiles.py— Replace the star import with an explicit import of the four names this module actually consumes._NODE_WORKLOAD_TOPand_PROFILE_LIMITare used directly in the profile builders, andClusterStateSummaryandSignalContextmust be present in module globals for the dynamic__all__list comprehension at the bottom of the file to re-export them, so importing exactly these four preserves both runtime behaviour and the computed__all__. Note the underscore-prefixed names currently arrive via the wildcard only becausecluster_state_contractlists them in its own__all__; importing them... (truncated)
Links
/api/admin/audit/events, event typeshermes_autotriage_incidentandhermes_autotriage_diagnosis.Filed automatically by Ariadne from a Hermes Agent diagnosis (run run_69ea5ad4d60d43ed9860639539924e5f). Hermes has no write access to this repository; no files or infrastructure were changed.