Skip to content

Migrates to vite@6 to drop base64 inlined worker source from all bundles #1762

Merged
Juice10 merged 43 commits intomasterfrom
juice10/pr-1637-tests
Feb 6, 2026
Merged

Migrates to vite@6 to drop base64 inlined worker source from all bundles #1762
Juice10 merged 43 commits intomasterfrom
juice10/pr-1637-tests

Conversation

@Juice10
Copy link
Member

@Juice10 Juice10 commented Nov 21, 2025

Unfreeze PR #1637 tests so the tests pass. Superseeds #1637

BREAKING CHANGE: Rename UMD global names from rrweb to rrwebRecord for the recorder and rrwebReplay for the replayer. This avoids conflicts when both are loaded on the same page.

Fixes #1578

Description from @ruiconti:

Investigation: #1578 (comment)
Motivation: #1568 (comment)

Opening this tentatively to see if there's interest in merging this, so consumers don't have to rely on patches to fix this issue. If there is, happy to comply with all the contributing guidelines, rebases to master, etc.

Resolves #1578

ruiconti and others added 11 commits January 24, 2025 14:41
Without this change, build would fail because the produced stylesheet assumes
the `package.json['name']` i.e., `styles/rrweb.css`. To maintain the existing
behavior, these changes are required.

See https://vite.dev/guide/migration.html#customize-css-output-file-name-in-library-mode
Update playwright dependency to latest version and refactor test execution options to use a shared configuration with increased timeout for stability.
Update playwright dependency to latest version and refactor test execution options to use a shared configuration with increased timeout for stability.
@changeset-bot
Copy link

changeset-bot bot commented Nov 21, 2025

🦋 Changeset detected

Latest commit: 57e5f26

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 19 packages
Name Type
@rrweb/record Major
@rrweb/replay Major
@rrweb/all Major
@rrweb/packer Major
rrweb-snapshot Major
rrweb Major
@rrweb/web-extension Major
rrvideo Major
rrdom Major
rrdom-nodejs Major
rrweb-player Major
@rrweb/types Major
@rrweb/utils Major
@rrweb/rrweb-plugin-console-record Major
@rrweb/rrweb-plugin-console-replay Major
@rrweb/rrweb-plugin-sequential-id-record Major
@rrweb/rrweb-plugin-sequential-id-replay Major
@rrweb/rrweb-plugin-canvas-webrtc-record Major
@rrweb/rrweb-plugin-canvas-webrtc-replay Major

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

…cess

Add detailed console.log statements throughout the transformToVideo function to track execution flow and debug potential issues. Logging covers browser launch, context creation, page navigation, replay progress, and video file operations.
…bility

- Add Playwright Chromium installation step to CI workflow
- Change test execution stdio from 'pipe' to 'inherit' for better debugging
…t listeners

Set autoPlay to false in replayer configuration and manually call play() after all event listeners are attached. This ensures event handlers are properly registered before playback begins, preventing potential race conditions.

Also refactor test execution options to separate stdio configuration from timeout settings for better control over test output visibility.
Add comprehensive error handling to prevent hanging during video transformation:
- Add 2-minute timeout for replay finish event
- Add console and error listeners for better debugging
- Improve promise chain with proper error catching
- Clear timeout on successful completion or error

This prevents the process from hanging indefinitely when the replay finish event never fires.
Wrap replayer initialization in try-catch block to handle potential errors gracefully. Restructure Player instantiation to use rrwebPlayer directly instead of rrwebPlayer.Player, and move width/height into props object for correct API usage. On error, log to console and trigger onReplayFinish callback to prevent hanging state.
@Juice10 Juice10 changed the base branch from juice10/rrvideo-test-update to master January 2, 2026 10:16
Copy link
Contributor

Copilot AI commented Jan 2, 2026

@Juice10 I've opened a new pull request, #1768, to work on those changes. Once the pull request is ready, I'll request review from you.

Copilot AI review requested due to automatic review settings January 2, 2026 10:31
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR upgrades major dependencies (Vite 5.x → 6.0.1, Playwright 1.32.1 → 1.56.1, esbuild 0.21.5 → 0.24.2) across the entire monorepo and fixes critical issues in the rrvideo package to unfreeze tests from PR #1637. The changes focus on resolving playback stalls in rrvideo by refactoring how rrweb-player is initialized, adding comprehensive error handling and debug logging, and ensuring Playwright browsers are properly installed in CI.

  • Major dependency upgrades across all packages (Vite, Playwright, esbuild)
  • Fixed rrvideo playback issues with improved player initialization and error handling
  • Added debug logging and timeout handling for better troubleshooting

Reviewed changes

Copilot reviewed 26 out of 27 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
yarn.lock Updated lockfile with new versions of esbuild (0.24.2), playwright (1.56.1), vite (6.0.11), and related dependencies including new optional platform dependencies
vite.config.default.ts Added cssFileName configuration and removed commented rollup options
packages/*/package.json (18 files) Updated vite dependency to ^6.0.1 across all packages; updated playwright to ^1.56.1 in rrvideo
packages/rrweb/package.json Added new CSS export path "./dist/rrweb.css"
packages/rrvideo/src/index.ts Refactored replayer initialization from Player class to direct constructor, added try-catch error handling, manual play() call, extensive debug logging, timeout mechanism, and console/error listeners
packages/rrvideo/test/cli.test.ts Added timeout configuration (60s) and changed stdio from 'pipe' to 'inherit' for better debugging
.github/workflows/ci-cd.yml Added step to install Playwright chromium browser before running tests
.changeset/*.md Added changesets documenting patches for rrvideo improvements and dropping base64 inlined workers

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@@ -0,0 +1,2 @@
---
---
Copy link

Copilot AI Jan 2, 2026

Choose a reason for hiding this comment

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

This changeset file appears to be empty except for the frontmatter. An empty changeset may not be intentional and could cause issues with versioning. Either this file should be removed, or it should include a description of what changes were made and which packages are affected.

Suggested change
---
---
This changeset file contains no versioning information and was created accidentally; it can be safely removed when cleaning up changesets.

Copilot uses AI. Check for mistakes.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@Juice10 Juice10 changed the title [draft] Experiment: unfreeze PR #1637 tests Experiment: unfreeze PR #1637 tests Feb 6, 2026
@Juice10 Juice10 changed the title Experiment: unfreeze PR #1637 tests Unfreeze PR #1637 tests Feb 6, 2026
@Juice10 Juice10 changed the title Unfreeze PR #1637 tests Migrates to vite@6 to drop base64 inlined worker source from all bundles Feb 6, 2026
eoghanmurray
eoghanmurray previously approved these changes Feb 6, 2026
Co-authored-by: Eoghan Murray <eoghan@getthere.ie>
@Juice10 Juice10 merged commit 22bc4c3 into master Feb 6, 2026
11 checks passed
@Juice10 Juice10 deleted the juice10/pr-1637-tests branch February 6, 2026 14:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Using RRWeb in chrome extension results in obfuscated code

4 participants