Repository navigation
docs: correct who can type into the Terminal and how Linux hosts it - #340
Merged
Merged
Conversation
- architecture.md item 11 said the in-process Terminal still offers `run` to the AI pane. It doesn't: the shell announces the module's read-only manifest, and the pane and `AiBus::shell_call` call only declared tools. The real gap is that only the system agent's `terminal.run` checks `sandbox::launch_sandboxed`. A process Terminal offers the AI pane its own `run` either way, and developer mode grants `terminal.run` to every covered app agent. On Windows there is no sandbox. - architecture.md item 8 said `terminal.run` is never offered on Windows. That holds for the system agent only. - README: OpenGL does not mean a CPU copy. Makepad exports DMA_BUFs through EGL and copies only when that fails. The shell runs the Terminal as a process on Linux only in a Vulkan build in a Wayland session. Task, with no module, is a process either way. - desktop/README app-terminal row: - the AI pane types only into a process Terminal; - outside developer mode it waits for a host sheet; - the limit is 4 KiB; - the shell uses `cargo build`, not `cargo run`; - phone builds don't link the Terminal; - #94 closed unmerged. English and Chinese change together. Co-Authored-By: Claude Opus 5.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.
What
This corrects four statements in the docs, in English and Chinese. I found them while re-checking the code issues listed in #333.
docs/architecture.md, "Where the code and the ADRs disagree", item 11 (from #333)run, so the AI pane can type into it.terminal.runchecks the sandbox.The AI pane can use a process Terminal's own
runwhether or not the Terminal's sandbox applied. In developer mode, the host-tool relay grantsterminal.runto every covered app agent without that check. On Windows there is no sandbox, so both paths reach an unsandboxed Terminal.The in-process Terminal is read-only on the bus, as the ADR says.
terminal.runis never offered on Windows.README.md, "Zero-copy frames for process apps" (from #331)desktop/README.md, theapp-terminalrow- in either hosting the assistant may type a command;
- the command is confirmed on the assistant's card;
- a command too long for the card is refused;
- the app is built with
cargo run;- it runs in-process "as on phones";
- release packages are waiting on #94.
cargo buildand starts it itself. Phone builds don't link it. Release packages ship onlyoctosenseand the kernel (#94 closed unmerged).Evidence
At
a287d530and the Makepad pinc155f61d.crates/shell/src/module_host.rs:573). That is Makepad'sread_only_manifest(apps/terminal/src/module.rs:80).host_executorswaps the executor (:608). The instance keeps this manifest (:616).crates/shell/src/lib.rs:2590and:2611register it. Replays and re-announcements reuse it.libs/ai/services/src/engine/core.rs:551-553).AiBus::shell_callfilters by the same manifest.crates/shell/src/sandbox/mod.rs:493).runincluded (Makepadapps/terminal/src/main.rs:379).system_chat/grants.rs:205andshell/menu.rs:879read the sandbox state.ai_bus.rsandhost_tools/relay.rsdon't.Catalog::may_call(host_tools/relay.rs:354-360) grants every shareable tool except the toolbox's.aichatbinary (desktop/packaging/release.json).app-aichatfeature.crates/shell/src/lib.rs:2343-2344).eglExportDMABUFImageMESA(platform/src/os/linux/x11/opengl_x11.rs:30-115). It falls back to a software readback only when that fails (platform/src/os/shared_framebuf.rs:437-466).vulkan_wayland()holds (crates/shell/src/apps.rs).AppRegistry::hostingappliesprocess-if-vulkanonly to linked modules, and Task's entry has"module": null.app-terminalrow.crates/shell/src/clients.rs:22and:1030saycargo build, nevercargo run.shells.phoneisoff.ai_bus.rs:437: the host sheet shows the arguments in full.apps/terminal/src/ai.rssetsMAX_COMMAND_BYTESto 4 KiB.octosense(crates/shell/src/apps.rs:57).Not in this PR
App Hub: its own agent, with read tools only #339 gave App Hub an agent, but
docs/architecture.mdstill shows App Hub without one:That's a separate change.
ADR 0004's tables still say OpenGL means "CPU readback of every frame" and "in-process for every app", and so does the
tools/native_apps.pydocstring. The ADR is a dated record, and this PR changes no code.The code gaps themselves are listed in docs: bring docs/ up to date with the code and rewrite the guides to the README's standard #333's description.
Verification
git diff --checkis clean.python3 -m unittest discover -s rom/tests -p test_no_local_paths.pypasses.🤖 Generated with Claude Code