sync: replace storeCaps with one unexported syncBackend interface; drop WriteHookStore #1219
All Vouch review confidence checks passed
Residual risk 0.26 = Change Risk (0.47) × (1 − Review Confidence (0.45)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.47 · 286 lines diff across 3 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.339
Real PR Conversation Timeline
1 comments
"Review active on #1219"
general
weight: 0.35
ggreer
Two commits; #1220 was squashed into this branch.
syncBackendreplacesstoreCaps.pkg/syncno longer resolves optional store capabilities.storeCaps,readerCaps,resolveStoreCaps,resolveReaderCaps, and thestoreCapsMatrixoracle are gone. In their place is one unexported interface,syncBackend(pkg/sync/sync_backend.go):c1zstore.StoreplusPageLedgerStoreplus the small interfaces that already existed for deleters, expansion layers, ingest facts, verification markers, digest, and graph blob.setStoreasserts it once;s.storeis asyncBackend; everys.caps.X.M(...)iss.store.M(...).c1zstore.Storedoes not change. Of its 53 methods, 37 have a caller in c1 or thebatonCLI; the 47 methodssyncBackendcovers have none outside this module and one implementer, so they stay module-private. c1 is unaffected.Sixteen nil arms are deleted, each the branch a non-Pebble store took. The largest is the ingest-invariants "referential checks skipped for this engine" path (
requiresStore,logSkippedReferentialInvariants,storeCarriesTypeScopedTypes), unreachable once the ingest-fact store is required.RunIngestInvariantserrors instead when handed a store without it;GraphFromStorekeeps returningnil, nil, since callers outside the syncer hand it bare stores.NewExpanderStorereturns an error instead of building a degraded adapter; the compactor is its only caller. Eight one-line forwarders onpebbleStoresurface methods that lived only onGrants()/SyncMeta().DBSizeProviderstays an optional assertion at its one call: it isEngine-only and the nil arm is real.The
Metadata().Engine == "pebble"compare insetStoresurvives for now; two tests build a store with the method set and a non-Pebble engine name. Dropping it,storeAttachErr, and the checklist rewrite are the next PR.WriteHookStoredeleted.SetWriteHookis a test-only tripwire: tests install it to fail any store write that bypasses the page ledger. Nothing in production calls it. The exportedc1zstore.WriteHookStoreinterface and thestoreCaps.writeHookfield are gone; the method stays on the unexporteddotc1z.pebbleStoreand tests reach it through a_test.go-localwriteHookSetter. No assertion was weakened.