Skip to content

test(#11): assert the RowDescription-shifted manifestation in the pool-desync harness - #18

Merged
solidcitizen merged 1 commit into
mainfrom
test/issue-11-rowdescription-assertion
Sep 14, 2026
Merged

solidcitizen merged 1 commit into
mainfrom
test/issue-11-rowdescription-assertion

Conversation

@solidcitizen

Copy link
Copy Markdown
Owner

Test-only follow-up to #11 (no library change, no release).

NexusPlus's consumer-contract suite surfaced a second 1.0.2 manifestation of #11 that bypasses an app-side checkout 'error' guard: a stray RowDescription landing on a client whose activeQuery is null makes node-postgres' Client._handleRowDescription throw uncaught rather than emit 'error'. The pool-desync.mjs harness previously caught the CommandComplete-shift and the silent shifted/empty result, but an uncaught crash showed up only as an opaque non-zero exit.

This adds a process-level uncaughtException/unhandledRejection trap that records a crash (tagging the RowDescription null-deref shape), prints the summary, and exits 2 — so the RowDescription-shift is asserted as a first-class failure. The three manifestations are documented in docs/adversarial-test-plan.md.

Verified: green on 1.0.3 (released), red on 1.0.2 (baseline/1.0.2); the trap + classifier verified against the exact Client._handleRowDescription null-deref shape (Cannot read properties of null (reading 'handleRowDescription')).

…l-desync harness

NexusPlus's consumer-contract suite found a second 1.0.2 manifestation of #11
that bypasses an app-side checkout 'error' guard: a stray RowDescription
landing on a client whose activeQuery is null makes node-postgres'
Client._handleRowDescription throw uncaught (not emit 'error'). The
pool-desync harness previously only caught the CommandComplete-shift and the
silent shifted/empty result; an uncaught crash showed up as an opaque
non-zero exit.

Add a process-level uncaughtException/unhandledRejection trap that records a
'crash' (tagging the RowDescription null-deref shape), prints the summary, and
exits 2, so the RowDescription-shift is asserted as a first-class failure.
Document the three manifestations in the test plan.

Test-only; no library change. Verified green on 1.0.3 (released) and red on
1.0.2 (baseline/1.0.2); the crash trap+classifier verified against the exact
Client._handleRowDescription null-deref shape.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 14, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-14T06:22:40.325033Z dc4dd1e PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@solidcitizen
solidcitizen merged commit d832f88 into main Sep 14, 2026
3 checks passed
@solidcitizen
solidcitizen deleted the test/issue-11-rowdescription-assertion branch September 14, 2026 06:22

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: dc4dd1e648

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

const PROTOCOL_RE = /unexpected \w+ message from backend/i;
// pg's Client._handleRowDescription does `this.activeQuery.handleRowDescription(...)`;
// a stray RowDescription with activeQuery === null throws this shape.
const ROWDESC_CRASH_RE = /Cannot read propert.*of null|handleRowDescription|activeQuery/i;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Require RowDescription details in the crash classifier

When any unrelated code in the harness or a dependency throws a null-property error such as Cannot read properties of null (reading 'foo'), the first regex alternative matches and the summary incorrectly labels it as the RowDescription-shift regression. Because this output is intended to distinguish that exact protocol manifestation from an ordinary harness crash, require the null-dereference shape and handleRowDescription/activeQuery evidence together rather than accepting every null-property TypeError.

Useful? React with 👍 / 👎.

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