cow: ratify the retry classification table against the upstream errorType enum - #464
Conversation
lgahdl
left a comment
There was a problem hiding this comment.
Clean. Confirmed cowprotocol is correctly under [dev-dependencies] (not [dependencies]), matching the comment's claim that it's parity-test-only and never reaches a runtime/guest build. The removed PriceExceedsMarketPrice row is exactly what the new every_row_names_a_real_error_type test would have caught (phantom type not in the upstream enum). The second new test, divergence_from_upstream_is_exactly_the_ratified_set, is a well-designed drift guard — it projects the upstream retry_hint() into shepherd's model and pins the exact 5-entry divergence set, so either a future data edit or an upstream RetryHint change (including a hypothetical new variant, which the wildcard arm would correctly surface as new divergence) forces re-ratification rather than silently drifting. The old shepherd-sdk::cow::error test was correctly updated to drop the removed case. Approving.
6b739d7 to
15b3a00
Compare
…Type enum Prune the phantom PriceExceedsMarketPrice row, record the table (not cowprotocol RetryHint) as the classification source of truth in the data header, and pin the reconciliation with parity tests: every row must name a real upstream errorType, and the divergence from retry_hint() must be exactly the ratified set.
ef62240 to
95ea541
Compare
…Type enum (#464) Prune the phantom PriceExceedsMarketPrice row, record the table (not cowprotocol RetryHint) as the classification source of truth in the data header, and pin the reconciliation with parity tests: every row must name a real upstream errorType, and the divergence from retry_hint() must be exactly the ratified set.
What
Finish ratifying
cow-venue/data/classification.toml: prune the phantomPriceExceedsMarketPricerow (absent from the real CoWerrorTypeenum), reconcile the table against the upstream enum, and record the source-of-truth decision.Why
The divergence rationale already sat in the table header; this closes it out with parity tests so the classification can't drift from the upstream enum.
Testing
Full gate green (fmt, check, clippy -D warnings, nextest, doctests).
AI Assistance
Implemented and red-teamed with Claude.
Closes #323.