Skip to content

SWF(bug): ship React WebUI in dev and release builds - #70

Merged
devin-ai-integration[bot] merged 3 commits into
refactor/pilo-designfrom
devin/1796439911-ship-react-webui
Dec 5, 2026
Merged

devin-ai-integration[bot] merged 3 commits into
refactor/pilo-designfrom
devin/1796439911-ship-react-webui

Conversation

@hsingjui

@hsingjui hsingjui commented Dec 5, 2026 •

Copy link
Copy Markdown
Owner

Switch pnpm dev and the release WebUI job from the legacy nsh packager (scripts/build-nsh-web.mjs) to the Vite React WebUI build so both dev and release builds actually ship the React Remote WebUI.

改动说明

  • scripts/dev.mjs: Build the React WebUI via Vite into .nsh/web-dev-out staging, publish assets before atomically swapping dist/index.html with pilo-dev-reload.js injected (preserving the last good build on failed rebuilds), and point --web at Vite instead of legacy nsh dev --target web.
  • .github/workflows/release.yml: Update the webui job to set up pnpm + Node 22, install frozen dependencies, run pnpm build:web, and verify the bundle with scripts/verify-react-webui.mjs. Artifact upload/download and desktop packaging are unchanged.
  • scripts/verify-react-webui.mjs & tests/unit/webui-build.spec.mjs: Regression tests verifying the dev launcher, release workflow definition, and pnpm build:web output produce <div id="root"></div>, an existing /assets/*.js module, and no legacy nsh-app/nsh-fetch metadata.

Legacy WebUI dead-code assessment (not removed in this PR): web/App.tsx / web/WebApp.tsx are no longer shipped, but legacy files cannot be deleted wholesale yet because app/tests/mobile-web-fixture.tsx, app/tests/web-workspace-storage.test.ts, tests/unit/optimize-web-bundle.spec.mjs, and scripts/release-version.py (web/nsh.json) still reference them, and React itself imports web/transcript-subscriptions.ts.

验证方式

Try it:

node --test tests/unit/webui-build.spec.mjs && pnpm build:web && node scripts/verify-react-webui.mjs

Before fix (tests/unit/webui-build.spec.mjs): 1 pass, 2 fail

  • AssertionError [ERR_ASSERTION]: Expected a React root in dist/index.html
  • AssertionError [ERR_ASSERTION]: Expected the release WebUI job to run pnpm build:web

After fix:

  • node --test tests/unit/webui-build.spec.mjs: 3/3 pass (dev launcher, release WebUI job, release build).
  • pnpm test: 350 unit + 22 integration pass, 0 fail.
  • pnpm check: pass.
  • pnpm build:web && node scripts/verify-react-webui.mjs: built in 1.59s, exit 0.

Real macOS Host runs (ARM64):

  • pnpm dev Host (http://172.16.4.2:48511/): 200 text/html with <div id="root"></div>, /assets/index-DU-3ojfM.js (200), /pilo-dev-reload.js (200), and no nsh-app/nsh-fetch. Rendered in Chrome at /pair:

pnpm dev Host serving React WebUI

  • Release-style packaged Pilo.app (0.0.0-verify) (http://172.16.4.2:27237/, tested with repo dist/ moved aside): 200 text/html matching Contents/Resources/webui/index.html SHA-256, <div id="root"></div>, /assets/index-DU-3ojfM.js (200), /pilo-dev-reload.js (404), and no nsh-app/nsh-fetch. Rendered in Chrome at /pair:

Packaged Pilo.app Host serving React WebUI

Untested:

  • Pairing flow and authenticated workspace inside these two runs (verified separately in the integration report).
  • Hosted GitHub Actions release.yml execution, macOS signing/notarization, and Windows/Linux release builds.
  • Running the Node tests under Node 22 specifically (local Mac ran its installed Node runtime; verify-react-webui.mjs uses process.argv[1] / fileURLToPath for Node 22 compatibility).

Software Factory opened this PR for Jui
Implemented in session Ship the React WebUI in dev and release builds
Review with Devin · Open in Devin Desktop


@devin-ai-integration

Copy link
Copy Markdown
Contributor

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

@coderabbitai

coderabbitai Bot commented Dec 5, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@devin-ai-integration
devin-ai-integration Bot merged commit e6cd615 into refactor/pilo-design Dec 5, 2026
5 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.

1 participant