Skip to content

Ensure WASM artifact exists for static Pages/Preview deployments#2

Draft
Copilot wants to merge 4 commits into
mainfrom
copilot/fix-github-pages-access-issue
Draft

Ensure WASM artifact exists for static Pages/Preview deployments#2
Copilot wants to merge 4 commits into
mainfrom
copilot/fix-github-pages-access-issue

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 13, 2026

js/app.js imports wasm-fft/pkg/wasm_fft.js, but static publish flows can ship without pkg if WASM is not built first. This PR aligns local/preview deployment with the actual runtime requirement by making pkg generation explicit and repeatable.

  • Preview publish flow: generate wasm-fft/pkg before copy/deploy

    • Adds Rust toolchain + wasm-pack setup in preview workflow.
    • Builds wasm-fft with --target web --release.
    • Fails fast with explicit diagnostics when pkg/wasm_fft.js is missing.
  • WASM build reliability

    • Sets wasm-pack release profile to disable wasm-opt download dependency in wasm-fft/Cargo.toml for more predictable CI/local builds.
  • Developer docs

    • Updates README usage flow to include wasm-fft build before serving the repo as static files.
# .github/workflows/PRview.yml
- name: Build wasm-fft package
  run: |
    cd wasm-fft
    wasm-pack build --target web --release
    if [ ! -f pkg/wasm_fft.js ]; then
      echo "ERROR: wasm-fft/pkg/wasm_fft.js not found after wasm-pack build"
      ls -la pkg || true
      exit 1
    fi

Copilot AI and others added 4 commits May 13, 2026 00:06
Agent-Logs-Url: https://github.com/Fyphen1223/AudioAnalyzer/sessions/d55e9936-4b49-44bd-93ce-b7a1acfbc31a

Co-authored-by: Fyphen1223 <89511960+Fyphen1223@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Fyphen1223/AudioAnalyzer/sessions/d55e9936-4b49-44bd-93ce-b7a1acfbc31a

Co-authored-by: Fyphen1223 <89511960+Fyphen1223@users.noreply.github.com>
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