Skip to content

harness: the PostgreSQL value-refusal cells read the remedy sentence from the product's text_remedy and run the declared-text remedy (see #1233) - #1247

Open
panchenkoai wants to merge 1 commit into
mainfrom
harness-1233-remedy-wording
Open

panchenkoai wants to merge 1 commit into
mainfrom
harness-1233-remedy-wording

Conversation

@panchenkoai

Copy link
Copy Markdown
Collaborator

Why

#1233 changed the PostgreSQL value-refusal wording (the remedy is now "Declare col: text under columns: ... or project the column in the export's query:"). Three live cells still asserted the old phrases, so Nightly Live is red (runs 45707637420, 45746063461 on 1d15cf1):

  • live_operator_contract::an_unrepresentable_value_is_refused_by_code_postgres (remedy cell: "the refusal no longer says maps the sentinels to a real bound")
  • live_type_policy::a_postgres_two_dimensional_jsonb_array_keeps_the_multi_dimensional_refusal
  • type_roundtrip pg_edge_cases::pg_edge_multidim_array_fails_loud_not_silent_null

The product text is the owner-intended #1233; the tests were stale.

What

  • One sentence, one source: rivet::types::text_remedy (was pub(crate)) is re-exported; tests/common exposes text_remedy and says_text_remedy over it. The three cells derive the sentence from the product, so a later wording change cannot leave them stale.
  • The remedy cell now RUNS the declared-text remedy (columns: { t: text } delivers the source, graded by the default oracle) besides the query projection. The old PG "exclude the column" remedy is dropped: the refusal no longer names it.
  • Swept the repo for the old phrases (maps the sentinels to a real bound, cast-to-text, ::text/cast hints, Declare \``) in tests/ and dev/: no other cell asserts them. The CDC stream wording (NOT_ONE_DIMENSIONAL`, src/source/cdc/value.rs) is unchanged by types: a PostgreSQL date, time, timestamp or array column declared text is delivered as the server's text, and the value refusals name that remedy #1233 and its lib test still holds. MySQL/MSSQL/Oracle cells assert their own sentences and codes, not this one.
  • Changelog fragment (harness only, no behaviour change).

Invariants

  • I1: not applicable, no behaviour change (a function made pub and re-exported).
  • I2: not applicable.
  • I3: not applicable.
  • I4: not applicable.
  • I5: not applicable.

Evidence

step command result
RED on main 1d15cf1 (devbox, live_slot) nextest live_suite the two cells; type_roundtrip the third Summary 2 tests run: 0 passed, 2 failed; refuse-then-remedy: the refusal no longer says 'maps the sentinels to a real bound'; Summary 1 test run: 0 passed, 1 failed (the failure must name the cast-to-text remediation)
GREEN on branch (same env) same commands Summary 2 tests run: 2 passed (remedy cell test result: ok. 1 passed, both oracle grades PASS dst_count 2); Summary 1 test run: 1 passed
pre-commit + pre-push hooks fmt, clippy, lib+offline suite passed (devbox push)

Not verified here: repeat x5, the gate-env pass with a Postgres state URL (remedies are skipped there by design, named skip), seeded-recall, mutants on CI.

…from the product's text_remedy and run the declared-text remedy (see #1233)

Why: #1233 changed the PostgreSQL value-refusal wording; three live cells still asserted the old phrases and the nightly went red.

What: types::text_remedy is the one sentence; the operator-contract remedy cell, the two-dimensional jsonb[] cell and the multi-dimensional int[] cell read it from there, and the remedy cell runs the declared-text remedy besides the query projection.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant