Skip to content

feat(files): 在 Web 工作区定位目录并安全新建文档 / reveal project folders and create reviewed documents in the web workbench - #17

Draft
Facetomyself wants to merge 7 commits into
feat/web-workbench-sandbox-handofffrom
feat/web-workbench-project-documents
Draft

Facetomyself wants to merge 7 commits into
feat/web-workbench-sandbox-handofffrom
feat/web-workbench-project-documents

Conversation

@Facetomyself

@Facetomyself Facetomyself commented Nov 27, 2026 •

Copy link
Copy Markdown
Owner

Stacked on #16; refs sqfcyily#67. Adds the manual project-document workflow to the original desktop-derived workspace screen. It does not give the model file access or execution authority.

  • Reveal folder works with ordinary read-only grants: the workbench re-reads the selected project and each required directory, expands the chain, focuses the actual folder row and keeps the current editor/draft. The attached project can similarly be revealed at its root. It never invokes the server's OS file manager.
  • The new optional Compose file is used in addition to the existing editable-project override. Existing browse-only and edit-only deployments keep exactly their previous grants. Native file mode, mount and runtime checks still apply.
  • Review binds one absent relative name to the current login and the held directory chain for two minutes; preparing creates no file. Explicit Create publishes one existing-directory Markdown or plain-text document (2 MiB limit; owner-only 0600) with an atomic no-overwrite hard link, directory sync, same-inode readback and the regular editor's revision. Competing prepares can coexist; only one exact name can be created. A symlink, directory swap, revoked login or expired review is not authority for a replacement. Ambiguous publication is never automatically retried: explicit Verify checks the original receipt and file bytes. Native side effects are not hidden by deleting someone else’s file.
  • Gate covers two independent owner logins, exclusive creation, preserved conflict draft, interrupted 201 response with no duplicate write, Unicode text, BOM/CRLF in the native tests, POSIX access checks and login revocation while a request is still uploading. The packaged gate uses the real runtime image, native volumes and a confined synthetic project, verifying the default, edit-only and create modes and a distinct replacement container.
  • Inventory: 48 complete / 37 partial / 97 without recorded scope / 4 desktop-only, plus the separate implemented platform value. Only fs.revealFolder is newly complete; fs.writeFile remains partial because new-file support is deliberately restricted to ordinary document names and formats. The optional browser's last tested Docker sandbox limitation remains separate from document management.

Measured evidence at 9f7d431

  • Production workspace, native file protocol and authenticated tests: locally 451/451 server tests and 179/179 workbench checks passed with no skips. Types and the production web bundle passed. The transport also rejects duplicate JSON members (including differently escaped names), and withdrawing the login while a chunked creation body was still arriving produced 401 without writing a file.
  • Two independent real sandboxed Chrome profiles, Linux arm64, Chrome for Testing 158.0.8127.88, local private pipes. Ran the checked-in workspace UI scenario against the built workbench and the true native server with trusted browser input. Revealing a previously collapsed nested directory moved DOM focus to that folder, and canceling a prepared root document left the directory unchanged. Independent logins reviewed the same absent file, exactly one became a 0600 file (HTTP 201) and the second got 409 with its full local draft preserved. A purposely truncated successful creation response left the result unconfirmed; the Verify button read the original status, listed the folder and read back the exact native bytes/revision without another create. Zero model requests. Both browser profiles, ephemeral service, fixture and observers were cleaned up. The final screenshot was inspected after fixing an old save notice that otherwise referred to the formerly selected document. This is local real browser evidence, not a hosted W3C or native amd64 package receipt.
  • Workbook exporter verified the preload AST, Git tree and evidence files before writing the four-sheet workbook: 186 method rows, 18 included subscriptions, 531 links to exact-commit source/test blobs, separate platform value; SHA-256 1d40bfc32f48156badf4de62a5043326be29576a67ba94615af2ea705206559b with --repo Facetomyself/deva --pr 17.
  • Pending: the ordinary hosted W3C run and the actual new amd64 Compose container-recreation run. No Actions run was returned for this PR head; dispatch on its named branch returned HTTP 422, “Actions has been disabled for this repository.” No repository or host security settings were changed. --fixture-only passed (real POSIX access ACL grant and readback, fixed probe syntax; no Docker daemon contact). The real Compose parser confirmed base/no project, read-only, edit-only and opt-in create configurations. The full gate can also be run on a disposable native Linux/amd64 machine with an explicit --disposable-image sha256:<id> and a prebuilt image, as described in the operator instructions. Do not count that still-unrun gate as a successful release.

Additional build and visual verification

The original Electron main/preload/renderer and mobile production bundles also built successfully from this tree. No desktop launch or mobile device runtime was inferred from that build. A final clean-checkout-equivalent run of the local private-pipe Chrome scenario retained the updated file/folder focus without showing a success notice for another file. The final inspected 1280×800 synthetic screenshot has SHA-256 82d9b1022c3cca555e70e6d93edc1d2518404e2b89780f6ba0fd791faf559d4b. The pinned workbook export was generated twice and reused identical bytes. Study the local/hosted distinctions above before calling this a Docker deployment.

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