Skip to content

Conversation

timsaucer
Copy link
Contributor

Related

The recent addition of datafusion dependency has made our wasm size too large to upload to some places. This PR introduces a series of build options to reduce the blob size.

What

This PR adds a build profile specific to minimizing file size. Additionally it changes the web build tool to use this profile when the --release parameter is set.

Copy link

github-actions bot commented May 2, 2025

Web viewer built successfully. If applicable, you should also test it:

  • I have tested the web viewer
Result Commit Link Manifest
6be77f6 https://rerun.io/viewer/pr/9870 +nightly +main

Note: This comment is updated whenever you push a commit.

Copy link

github-actions bot commented May 2, 2025

Latest documentation preview deployed successfully.

Result Commit Link
6be77f6 https://landing-cp7pmpqsc-rerun.vercel.app/docs

Note: This comment is updated whenever you push a commit.

@jprochazk
Copy link
Member

One thing that I don't have time to check right now is if the wasm build still works. There is a script in rerun_js/web-viewer/build.mjs that patches the output of wasm-bindgen in a crude way (string replace). We need to make sure the patch is still being applied properly

@timsaucer
Copy link
Contributor Author

At least part of it is failing, but I need to step away. I'll pick this back up monday morning.

@timsaucer timsaucer added 📉 performance Optimization, memory use, etc ⛴ release Related to shipping or publishing include in changelog 🚢 CI labels May 5, 2025
@timsaucer timsaucer self-assigned this May 5, 2025
@timsaucer timsaucer marked this pull request as ready for review May 5, 2025 14:31
@timsaucer timsaucer requested a review from jprochazk May 5, 2025 14:31
Copy link
Member

@abey79 abey79 left a comment

Choose a reason for hiding this comment

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

Lgtm. @jprochazk would you think it's worth triggering an alpha to test the build?

@jprochazk
Copy link
Member

@rerun-bot full-check

Copy link

github-actions bot commented May 7, 2025

@jprochazk
Copy link
Member

Still need to take a closer look at how this affects the build script, adding DNM for now

@jprochazk jprochazk added the do-not-merge Do not merge this PR label May 7, 2025
@jprochazk
Copy link
Member

jprochazk commented May 9, 2025

I've got some commits coming soon to fix the build-wasm.mjs script and pass -g through to the build again

@jprochazk jprochazk removed the do-not-merge Do not merge this PR label May 9, 2025
Copy link
Member

@jprochazk jprochazk left a comment

Choose a reason for hiding this comment

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

gzip .wasm is under 9MB now, so we've got some time before we have to think about this again

@jprochazk jprochazk added the 🕸️ web regarding running the viewer in a browser label May 9, 2025
@jprochazk jprochazk merged commit 9d4ece4 into main May 9, 2025
46 checks passed
@jprochazk jprochazk deleted the tsaucer/reduce-wasm-size branch May 9, 2025 13:29
@emilk emilk added this to the 0.23.3 (?) milestone May 15, 2025
@jprochazk jprochazk modified the milestone: 0.23.3 May 24, 2025
jprochazk added a commit that referenced this pull request May 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
include in changelog 📉 performance Optimization, memory use, etc ⛴ release Related to shipping or publishing 🚢 CI 🕸️ web regarding running the viewer in a browser
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants