Skip to content

deploy: keep Monaco WASM raw - #106

Merged
alixander merged 1 commit into
masterfrom
agent/keep-wasm-raw
Aug 6, 2026
Merged

deploy: keep Monaco WASM raw#106
alixander merged 1 commit into
masterfrom
agent/keep-wasm-raw

Conversation

@alixander

Copy link
Copy Markdown
Contributor

What changed

  • remove the post-deploy Brotli rewrite of dist/js/vendor/onig.wasm
  • keep WASM assets raw throughout the deploy and any subsequent mirror
  • retain the existing explicitly encoded JS and CSS uploads

Why

The deploy script synced dist first and then replaced dist/js/vendor/onig.wasm with Brotli bytes without uploading it or attaching Content-Encoding metadata. Reusing that mutated directory for the source-account mirror stored compressed bytes as an ordinary WASM object. The live CloudFront distribution compressed it again, and browsers received Brotli bytes instead of the WebAssembly magic header, preventing Monaco from initializing.

Keeping WASM raw makes the build directory safe to re-sync and mirror. Any future precompression must use matching object metadata.

Impact

Future playground deploys and mirrors will publish a directly usable onig.wasm instead of leaving a hazardous post-deploy artifact. This does not change the explicit Brotli handling for the large JavaScript and CSS bundles.

Validation

  • bash -n ci/deploy.sh
  • git diff --check

No new test was added.

@alixander
alixander marked this pull request as ready for review August 6, 2026 05:11
@alixander
alixander enabled auto-merge August 6, 2026 05:11
@alixander
alixander merged commit 7f4b680 into master Aug 6, 2026
4 checks passed
@alixander
alixander deleted the agent/keep-wasm-raw branch August 6, 2026 05:48
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