feat: move desktop runtime behind app server - #192
Merged
Conversation
added 15 commits
August 1, 2026 13:32
oratis
force-pushed
the
codex/canonical-thread-store
branch
from
August 1, 2026 07:05
801b4de to
1a92767
Compare
oratis
force-pushed
the
codex/desktop-protocol-runtime
branch
from
August 1, 2026 07:05
a9d45f7 to
06654f2
Compare
oratis
force-pushed
the
codex/canonical-thread-store
branch
from
August 1, 2026 07:20
1a92767 to
033f7e6
Compare
oratis
force-pushed
the
codex/desktop-protocol-runtime
branch
from
August 1, 2026 07:20
06654f2 to
e838092
Compare
This was referenced Aug 1, 2026
This was referenced Aug 2, 2026
oratis
marked this pull request as ready for review
August 2, 2026 06:41
Owner
Author
Review: approved ✅ — closes threat #1 for the desktop appThis is where the renderer stops being a trusted runtime. Per Verified in the Rust diff
Also good
Note: −1036 lines. Deleting the second agent loop is the real win — two implementations of the same policy is how the VS Code/LSP gate bypass in #181 happened in the first place. Validation: CI green; desktop 62 tests pass locally at the stack tip. |
This was referenced Aug 2, 2026
oratis
added a commit
that referenced
this pull request
Aug 2, 2026
…#214) Reworks #166, which was correct in approach but is now incomplete and carries stale docs. `permissions.additionalDirectories` has been declared in the settings schema and read by /permissions for display, but consumed for enforcement nowhere — /add-dir only printed "recorded ... (effective in M3)". Users could reasonably believe it did something. Why the sandbox is the right boundary: the file tools (Read/Write/Edit/ Glob/Grep) already accept any absolute path, so there is no cwd containment to widen. The only thing that actually restricts writes is the OS sandbox wrapping Bash. Enforcing /add-dir therefore means adding those directories to `filesystem.allowWrite`. The part #166 could not have covered: it predates the app-server, and wired only CLI REPL + headless. Since #192/#195/#196, desktop, VS Code and LSP all run through apps/server, so that wiring would have enforced the setting in the CLI and silently ignored it everywhere else — for a security-relevant setting, partial enforcement is worse than none, because it is indistinguishable from full enforcement at the UI. All 7 sandbox assembly sites across 4 files now route through the helper. - core `withAdditionalWritableDirs(sandbox, dirs, cwd?)`: pure, never mutates input, no-op when the sandbox is disabled (never silently enables it), dedupes, and drops non-absolute entries rather than handing them to profile writers that require absolute paths - /add-dir validates the path is an existing directory, stores it absolute (resolved against cwd), refuses duplicates, and lists the current set with no args - BEHAVIOR_PARITY: only the /add-dir row changes. #166 rewrote the whole table with June-era content that would have regressed /btw, /voice, /tasks and /background back to unshipped. (Prettier reflows the table columns; `git diff -w` shows the 2 real lines.) tsc -b --force, lint (--max-warnings=0), format:check, docs:check clean; 1048 tests pass (9 new helper + 6 new /add-dir); build clean. Co-authored-by: t <t@t> Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
oratis
pushed a commit
that referenced
this pull request
Aug 2, 2026
Supersedes #138 and #139, which are coupled (plugin-react 6 requires vite 7+) and were deferred in June because `vite build` failed with `Rolldown failed to resolve import "openai"` — vite 8 swaps in the rolldown bundler, and the renderer was transitively pulling core/dist/providers/deepseek.js. That blocker is gone: #192 split dependency-free model metadata from the provider implementation specifically so provider/OpenAI SDK code is absent from renderer bundles. The import rolldown could not resolve no longer reaches the renderer graph, so no `build.rolldownOptions.external` migration is needed. Also replaces `__dirname` with `import.meta.dirname` in vite.config.ts. vite 8 warns that `__dirname` is unsupported by `configLoader: 'native'`, which is planned to become the default in a future major. The repo requires Node >=22, so `import.meta.dirname` is available. Verified on top of React 19 (#211), forced rebuild throughout: - tsc -b --force, lint (--max-warnings=0), format:check: clean - 1033 tests across 8 packages: pass - pnpm build + full build:tauri-assets pipeline: pass (app-server.cjs 599,395 bytes — within the 768 KiB #208 budget) - desktop Playwright protocol journey (4 tests): pass Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
oratis
added a commit
that referenced
this pull request
Aug 2, 2026
Supersedes #138 and #139, which are coupled (plugin-react 6 requires vite 7+) and were deferred in June because `vite build` failed with `Rolldown failed to resolve import "openai"` — vite 8 swaps in the rolldown bundler, and the renderer was transitively pulling core/dist/providers/deepseek.js. That blocker is gone: #192 split dependency-free model metadata from the provider implementation specifically so provider/OpenAI SDK code is absent from renderer bundles. The import rolldown could not resolve no longer reaches the renderer graph, so no `build.rolldownOptions.external` migration is needed. Also replaces `__dirname` with `import.meta.dirname` in vite.config.ts. vite 8 warns that `__dirname` is unsupported by `configLoader: 'native'`, which is planned to become the default in a future major. The repo requires Node >=22, so `import.meta.dirname` is available. Verified on top of React 19 (#211), forced rebuild throughout: - tsc -b --force, lint (--max-warnings=0), format:check: clean - 1033 tests across 8 packages: pass - pnpm build + full build:tauri-assets pipeline: pass (app-server.cjs 599,395 bytes — within the 768 KiB #208 budget) - desktop Playwright protocol journey (4 tests): pass Co-authored-by: t <t@t> Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
oratis
added a commit
that referenced
this pull request
Aug 2, 2026
…ajors (#215) Covers the 31-PR Codex alignment stack (#180-#210) plus the dependency work (#211-#214, #155, #177-#179). Leads with the security section because that is what this release is: the central tool gate could be skipped entirely when `mode` was omitted (#181), and the desktop renderer held provider credentials (#192). Upgrade notes call out the two things a user could otherwise be surprised by — the ~6.7 MB → ~115 MB desktop size increase from the Node sidecar, and that the plugin capability RPC is not an OS boundary. Co-authored-by: t <t@t> Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Validation
Follow-up
Developer ID signing/notarization remains a release gate. Browser fixture and visual desktop journeys remain in the next stacked PR.