Skip to content

test(api): the customer rule surface through the public contract; inventory what exists (#515) - #1295

Merged
athvin merged 1 commit into
mainfrom
feat/515-customer-rules
Nov 27, 2026
Merged

athvin merged 1 commit into
mainfrom
feat/515-customer-rules

Conversation

@athvin

@athvin athvin commented Nov 27, 2026 •

Copy link
Copy Markdown
Owner

Closes #515

Post-merge is part of this pull request. The ledger below records whether
the follow-up work actually happened. /land-pr closes it.

pg_customer_rules (every advanced rule block through validate → draft → publish with an admin key, tier classification of a rule edit, five malformed rules refused with their messages, nothing stored) and er-matching/references/customer-rules.md (the inventory: block, what it expresses, what is checked, how it executes; the #515 properties; the real gaps). Gap ticket: #1294.

E7 (#515): inventory the rule surface before claiming a greenfield build; cover validated, versioned, bounded customer rules through the public API; separate generic from Salesforce rules. The inventory found the rule language already exists as the config.

Proof

pg_customer_rules passes against local Postgres (its first run also showed the validator explaining a survivorship-group mistake in my own fixture). make check: exit 0.

Risk & rollback

Test and docs only.

Post-merge ledger

Closed by: agent · session Claude Code:24d16c2e-fec6-49d8-9797-060338df4848 on brians-MacBook-Pro · 2026-11-27T03:59:27Z

  • main is green with this change on it — the merge SHA, and the run
    that proves it. A later head SHA with this commit as an ancestor counts;
    a cancelled run with zero jobs does not: 508e8d17 — rust 45933972435, frontend 45933972501, infra 45933972492 success
  • images built, or correctly never ran because nothing that goes into
    an image changed: 45933972505 success
  • deploy converged — proved by a line the running process emitted, not
    by the image digest and not by the workflow conclusion: deploy 45934381963 success; n/a for behaviour — the change is a test and a skill reference
  • the push-only surface no pull request can pre-test (deploy, drift,
    kind's nightly leg) is green, or knowingly red for a reason that is not
    this change: deploy green; drift/kind red for known reasons (Confirm the er-alerts email subscription and prove alert delivery #1056, kind probe red since 2026-11-10: KeyError 'token_hash' after the credential-omission fix #1106)
  • the board card reached Done through the automation rather than by
    hand, and the issue closed: E7 — Advanced customer-authored matching and survivorship rules #515 CLOSED via the merge
  • follow-ups are open for everything deferred here — numbers: Visual rule authoring over the config API #1294 (visual authoring)
  • what was learned is written down where the next session will find it
    (a skill, a reference, memory) — or nothing new was learned: er-matching/references/customer-rules.md is the rule-surface inventory

Specific to this change

Context — plan, discoveries, measurements, files

Plan

Discoveries

Measurements

Files

🤖 Generated with Claude Code

…entory what exists (#515)

E7 asked to inventory the rule AST before claiming a greenfield build. There
is a rule language, and it is the published config: cleanse transforms
(with regex and named dictionaries), hard constraints, blocking,
comparisons and cross-field comparison groups, segments, model ensembles,
and per-field and grouped survivorship — each declarative, column-checked
before a version exists, compiled into the SQL batch and online /resolve
both run, versioned with its config, and bounded (no customer code; RE2
regex).

pg_customer_rules publishes a config using every advanced block with a
tenant admin key, checks the published hash and the tier a rule edit
classifies into, and pins the refusal message for five malformed rules —
unparseable regex, a transform on a non-attribute, an unknown constraint
column, a missing dictionary, a survivorship group over an unknown field —
with nothing stored. er-matching/references/customer-rules.md is the
inventory; visual authoring is #1294.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@athvin
athvin merged commit 508e8d1 into main Nov 27, 2026
39 checks passed
@athvin
athvin temporarily deployed to marketing-preview November 27, 2026 03:24 — with GitHub Actions Inactive

This branch was previously deployed

1 inactive deployment
marketing-preview — 998b4bd5 Deployed Nov 27, 2026 by athvin via remove closed PR previews #89
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.

E7 — Advanced customer-authored matching and survivorship rules

2 participants