update consts and add discrete types for enums #46
All Vouch review confidence checks passed
Residual risk 0.18 = Change Risk (0.42) × (1 − Review Confidence (0.57)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.42 · 331 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.347
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #46"
general
weight: 0.35
robmry
document IPVS netlink constants and use explicit values
Replace iota-based constant definitions with explicit values matching
the Linux kernel's IPVS generic netlink interface.
Add comments identifying the corresponding kernel constants and links
to their definitions in the Linux UAPI headers.
This makes it easier to verify the values against the kernel and
prevents accidental changes to protocol values when constants are
added or reordered.
define a distinct type for IPVS netlink commands
Introduce an ipvsCmd type for IPVS generic netlink commands and
update the command helpers to use it.
This groups the command constants under a distinct type, allowing
linters such as exhaustive to detect missing cases in switches and
providing stronger type checking.
Keep the generic netlink request helper accepting uint8, as it is
also used for commands outside the IPVS family.
define distinct types for IPVS netlink attributes
Introduce dedicated types for IPVS command, service, destination,
and statistics attributes, using int as the underlying type to
match the netlink package's API.
Update the encoding and decoding paths to use these types, with
explicit conversions at the netlink API boundaries.
This improves type safety and allows linters such as exhaustive
to detect missing attribute cases in switch statements.
The attribute values and wire format remain unchanged.
deduplicate IPVS forwarding method constants
Use the ConnFwd constants as the canonical names for IPVS
forwarding methods, and deprecate the duplicate ConnectionFlag
constants while retaining them as aliases for compatibility.
Update internal references to use ConnFwd and document their
corresponding Linux kernel definitions.
Simplify lookupFwMethod by returning string literals directly
instead of indexing into a separate slice, and handle the
previously missing LocalNode and Bypass methods.
document IPVS scheduler name constants
Add a reference to the Linux kernel's IPVS scheduler implementations
to clarify where the scheduler names originate.
Unlike the netlink attributes and forwarding flags, these names
are registered as strings by the individual kernel schedulers,
rather than defined as UAPI constants.
use unix address family constants directly
Replace nl.FAMILY_ constants with their corresponding unix.AF_*
constants.
The netlink package aliases these constants to the Linux address
family values, so using golang.org/x/sys/unix directly avoids an
unnecessary layer of indirection and makes their origin explicit.