Skip to content

Spec 001 T035 follow-up: pdf.js's error never printed whole - #175

Merged
adamjohnwright merged 1 commit into
mainfrom
compare/cause-hidden
Nov 4, 2026
Merged

adamjohnwright merged 1 commit into
mainfrom
compare/cause-hidden

Conversation

@adamjohnwright

Copy link
Copy Markdown
Contributor

Spec 001, a follow-up to T035 (#173), from its review's lows.

  • UnreadPdf kept pdf.js's error as cause, which Node prints wherever it prints an error whole (console.error(error), an uncaught error), enumerable or not; pdf.js's message can quote the file's words (people's names, FR-013). Nothing printed it whole today, but nothing stopped it. It now keeps pdf.js's error in a private field, read with pdfError(). Tested by printing the error with util.inspect (the { cause } mutant fails).
  • Each of the console's writing methods is tested held during a comparison, from the test's own list (dropping assert and group from the code's list fails it).

Tests: test/check/unread.test.ts, test/compare/units.test.ts.

🤖 Generated with Claude Code

UnreadPdf keeps pdf.js's error in a private field, not as `cause`, which
Node prints with the error wherever it prints it whole. Tested by printing
the error with util.inspect. Every console writing method is tested held,
from the test's own list.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@adamjohnwright
adamjohnwright merged commit a2a53e1 into main Nov 4, 2026
2 checks passed
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