Skip to content

test: report why the Mermaid console-isolation render fails - #523

Draft
raiseCatError wants to merge 1 commit into
devfrom
test/mermaid-render-failure-reason-20261029
Draft

raiseCatError wants to merge 1 commit into
devfrom
test/mermaid-render-failure-reason-20261029

Conversation

@raiseCatError

Copy link
Copy Markdown
Owner

Diagnostic only, not a fix.

tests/browserConsoleChrome.test.ts ("a reload starts a new document; NMSh's find world, web pages and the Mermaid renderer never report") fails intermittently on the hosted macOS runner, shard 1/3: #514 (run 40630147755), #516 (run 40656373289), #521 (run 40755036517) and #522 (run 40755117211). Every failure is the same boolean assertion at line 106 (result.ok || result.code === 'syntax'), after roughly 13–16 s. The assertion discards the renderer's result, so the logs can't tell a render timeout from a crash or a protocol failure.

This change adds the renderer's code: reason (and the Mermaid version) as the assertion message. What passes and fails is unchanged: same expression, request, 10 s deadline and cleanup.

Not reproduced locally: with the pinned mermaid@12.2.0 bundle (integrity-checked like CI), 3/3 runs passed on dev and 3/3 on #516's head, plus 2/2 under full 8-core CPU load (1.1–1.4 s each). Leading hypothesis: the 10 s render deadline expires on the hosted runner. This is unproven, which is why this change exists.

The next hosted failure will report the code and reason, and the follow-up fix targets that.

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