Skip to content

feat(desktop): introduce React Desktop 2.0 - #776

Draft
abraxas914 wants to merge 7 commits into
lsdefine:mainfrom
abraxas914:codex/react-desktop-v2-upstream-final
Draft

feat(desktop): introduce React Desktop 2.0#776
abraxas914 wants to merge 7 commits into
lsdefine:mainfrom
abraxas914:codex/react-desktop-v2-upstream-final

Conversation

@abraxas914

Copy link
Copy Markdown
Contributor

Summary

This Draft PR introduces React Desktop 2.0 on top of the latest upstream main while preserving the existing static desktop as an independent v1 implementation.

The final candidate is based on upstream commit 30b24ad31d679cde47a75f47fb6880df1dd96891. That commit only changes frontends/stapp.py; the candidate keeps it byte-for-byte unchanged and adds the fork-validated desktop tree through seven reviewable commits.

Candidate commit: d2869df72a64edb3bee73fc8871516811bdd0e6f

Commit structure

  1. feat(desktop): introduce React Desktop 2.0 and runtime integration
  2. test(desktop): add unit, bridge, browser and native E2E coverage
  3. ci(desktop): add path-scoped quality gates
  4. docs(desktop): document v1/v2 boundaries and validation
  5. fix(packaging): restore curated macOS DMG layout
  6. feat(desktop): unify startup recovery with Semi Design
  7. build(desktop): reduce macOS package footprint

The first four commits are the conflict-resolved upstream integration. The final three are the independently reviewed and fork-accepted packaging, recovery-UI, and footprint hardening changes.

Architecture and scope

  • React v2 owns frontends/desktop/src/**, public/**, Vite inputs, and the packaged dist entry point.
  • frontends/desktop/static/** remains byte-for-byte identical to upstream and is not used as a React source tree.
  • The desktop always launches its package-owned desktop_bridge.py; external repositories are attached only through a compatibility-probed GA_ROOT.
  • move_ga_runtime remains registered and authorized with asynchronous copy, switch, rollback, and conditional-delete semantics; React v2 does not expose a migration UI in this PR.
  • Package, lockfile, Cargo, Tauri, and artifact metadata are aligned at 0.2.0.
  • The macOS package is prepared at build time, keeps the signed .app immutable at runtime, restores the curated two-item DMG layout, and excludes installed build tools and Python bytecode caches while retaining offline recovery wheels.
  • Loading, setup, fallback, connecting, root-error, and confirmation surfaces use Semi Design; the standalone fallback remains independent of React, Semi, and Vite chunks.

Upstream sync and boundaries

  • Latest upstream addition 30b24ad (fix(stapp): own stream bubble inside fragment for cross-version rerun safety) is preserved exactly.
  • A three-way merge-tree calculation completes without conflicts and is byte-for-byte equal to this candidate tree.
  • Relative to upstream: 312 paths, 54,042 insertions, and 849 deletions.
  • frontends/stapp.py, frontends/desktop/static/**, and memory/** have zero diff from upstream.
  • No .agents/**, .codex/**, .trellis/**, old QR images, fork-only nightly workflow, unresolved path, or conflict marker is present.
  • Only .github/workflows/desktop-ci.yml is added; the existing release workflow is modified only for the validated desktop packaging contract.

Validation completed locally on the exact candidate

  • Locked install: npm ci.
  • TypeScript: application and E2E type checks passed.
  • React/Vitest: 44 files / 351 tests passed.
  • Python: 124 passed / 1 skipped.
  • Rust: 11 production and 11 E2E-feature tests passed.
  • Packaging: 24/24 checks; CI contract passed.
  • Production build, bundle contract, and WDIO production-isolation contract passed.
  • Browser E2E: 2 specs / 7 deterministic journeys passed, including the Semi setup and standalone fallback rescue chain.
  • git diff --check and all static, memory, workflow, version, and local-only path invariants passed.

The candidate's complete desktop subtree is identical to fork main at 848547af90416f68aebbb998aeaa98680f61e67b. That fork SHA passed the complete Desktop Quality Gates and generated successful Windows, Linux, and macOS packages. The owner also completed an initial macOS package smoke without finding a functional regression.

Exact-candidate GitHub CI and same-SHA package artifacts will be generated after this branch is pushed and the Draft PR is opened. The PR should remain Draft until those checks are attached.

Known non-blocking observations

  • npm ci reports 20 inherited dependency findings (2 moderate, 18 high). No lockfile-mutating forced audit fix is included.
  • Vite reports one mixed static/dynamic import and a large main-chunk warning.
  • Upstream currently has no pull-request workflow for this path; this PR adds the path-scoped Desktop Quality Gates.

中文摘要

本 Draft PR 基于最新 upstream 30b24ad 引入 React Desktop 2.0,并严格保留原有 static v1。upstream 新增的 Streamlit 修复在候选中逐字节保持不变;static/**memory/** 以及本地 Trellis/Codex/agent 资料均不进入差异。

最终候选 d2869df 由七个可审阅提交组成:原四个生产、测试、CI、文档提交,加上已在 fork 验收的 DMG 布局修复、Semi 启动恢复界面和 macOS 缩包。准确候选已通过本地 351 项前端测试、124 项 Python 测试、Rust 11+11、24 项打包契约和 7 条浏览器旅程。推送后将补齐该 SHA 的 GitHub 门禁和三平台产物,在证据挂载前保持 Draft。

@yiqi-017

Copy link
Copy Markdown
Contributor

没有移动数据目录的功能。

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