Skip to content

Keep Jam out of the full-stack e2e harness - #198

Merged
Programcode merged 2 commits into
mainfrom
fix/jam-e2e-streaming
Oct 23, 2026
Merged

Programcode merged 2 commits into
mainfrom
fix/jam-e2e-streaming

Conversation

@Programcode

Copy link
Copy Markdown
Owner

Follow-up to #196. T7 found that the lib-add recipe fails on desktop and mobile on main: since #196, Jam loads on the first click in the middle of the test, and after that Playwright can't read the streamed ai response.

Real users are not affected. I checked production (debate.pi-stack.org) with the real Jam scripts loaded by a click:

  • Jam replaces window.fetch and XMLHttpRequest.prototype.send. ReadableStream is untouched.
  • A POST text/event-stream response with 4 events 500 ms apart reached the page one chunk at a time with Jam (522, 1014, 1515 and 2019 ms) and without it (518, 1017, 1519 and 2020 ms). The request body arrived intact.
  • In Jam's code, the stream override pipes the response through a TransformStream that enqueues every chunk as soon as it arrives. It does not buffer.

So no rollback was needed, and the loader stays as it is.

Change: the full-stack page fixture (e2e/full-stack/stack.ts), which both the gate and the verify-debatelab recipes use, now serves empty modules for https://js.jam.dev/**, so Jam never starts in those runs. The browser-only specs that cover Jam loading (startup-shell, loading-performance) are unchanged.

Jam now starts on the first click (#196), mid-test, and wraps window.fetch.
After that the lib-add recipe can no longer read the streamed ai response
in Playwright. Serve empty Jam modules from the full-stack page fixture,
which the gate and the verify recipes share. The app loader is unchanged.
Copilot AI balanced review requested due to automatic review settings October 22, 2026 21:59

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

Next included review available in 23 seconds.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
📥 Commits

Reviewing files that changed from the base of the PR and between 2cffa27 and c87128b.

📒 Files selected for processing: 1
  • e2e/full-stack/stack.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Note

🎁 Summarized by CodeRabbit Free

Your organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Essentials by visiting https://app.coderabbit.ai/settings/billing.

Comment @coderabbitai help to get the list of available commands.

@Programcode
Programcode merged commit c402ca6 into main Oct 23, 2026
1 of 4 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.

2 participants