Make the SPI `Event` type conform to `Identifiable`. #2075
All Vouch review confidence checks passed
Residual risk 0.37 = Change Risk (0.61) × (1 − Review Confidence (0.39)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.61 · 229 lines diff across 9 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 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
Shallow Review Depth
shallow_review_depth
0.344
Diff Size
diff_size
0.325
Self Review
self_review
0.140
Real PR Conversation Timeline
1 item
"Review active on #2075"
general
weight: 0.35
grynspan
This PR adds an
idproperty andIdentifiableconformance toEvent, an SPI type we use in Swift Testing to track events (shocking, I know).The ID of an event is a version 8 ("custom") UUID, unlike the IDs of some other types like test cases or tests. You might think that we would want to use the same hash-based ID we use for test cases, but:
1. Events don't always have associated hashable data, so two events might produce identical SHA-256 hashes as their IDs.
2. The domain for event uniqueness and identifiability is a test run, not all-of-time-and-space. It is okay if two events from separate test runs have the same ID, but two events in the same test run must _never_ have the same ID. Conversely, the same test case across two different test runs will ideally have the exact same ID so that it can be re-run manually.
3. The new
swift-structured-resultsrepository is expected to lean heavily on UUIDs as a currency type for identifying values like events.Note we cannot rely on Foundation to generate, parse, or present UUIDs since it is not always available (e.g. in Embedded Swift). Further, it cannot generate version 8 UUIDs for us. Hence, we roll our own logic. (Bleh.)
Checklist: