Skip to content

Approvals and questions: say "for you", never the shell's internal client id - #280

Merged
ymote merged 1 commit into
mainfrom
fix/no-client-id-in-prompts
Oct 2, 2026
Merged

ymote merged 1 commit into
mainfrom
fix/no-client-id-in-prompts

Conversation

@ymote

@ymote ymote commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

A headless instrument run of the desktop shell (main f52620c, frames 22, 34 and 35) found the "Ask " panel's internal client id shown to the person:

  • the question card: "News's agent asks (shell-ask)"
  • the approval sheet: "Asked by Calendar's agent for shell-ask"
  • the sheet's toast: "Calendar's agent for shell-ask asks. Open the sheet to approve or deny."

Cause. The panel opens the app's conversation as the client instance "shell-ask" (app_chat::INSTANCE). That id reaches the question as Request::client and the approval as Caller::OwnAgent { client }. questions::Request::asked_by and approvals::sheet::caller_label printed any client as given. A card's in-card chat has the same leak with "card-chat" (glance_chat::INSTANCE).

Fix. A turn from one of the shell's own surfaces where the person talks to an app's agent is the person's. The labels now say so, in the same form as the system agent's lane, which already reads "(for the assistant)":

  • the question: "News's agent asks (for you)"
  • the sheet: "Asked by Calendar's agent for you"
  • the toast and other notices: "Calendar's agent for you asks"

approvals::sheet::persons_surface knows the two surfaces: the panel and a card's chat. Any other client keeps the name it gave, for example "Rinx's agent for weather". The audit keeps the raw caller (own_agent/shell-ask), as it does for every caller.

Tests (Linux build host, from phone/; this branch alone):

  • cargo test --locked --features mobile-apps -p octosense-shell approvals: 59 passed, including the new the_persons_own_surface_reads_for_you_never_its_instance_id (the caller label, the sheet line and its notice).
  • … questions: 10 passed, including the new who_asks_names_the_person_never_the_shells_instance_id (the panel, a card's chat, the system agent's lane, a Rinx mini app).
  • … app_chat: 9 passed. … system_chat: 65 passed.
  • The whole shell suite as phone.yml runs it (cargo test --locked --features mobile-apps -p octosense-shell, with OCTOS_SHELL_TEST_KERNEL): 777 passed.
  • The two-lane scenario against the real kernel (pinned ae230ce): 5 passed.

Instrument (the same harness, on the Linux build host; before = main, after = this branch):

  • Before (main 4f73ab3; the same on f52620c): the card read "News's agent asks (shell-ask)", the sheet "Asked by Calendar's agent for shell-ask", and the toast "Calendar's agent for shell-ask asks. Open the sheet to approve or deny." (frames 22, 34, 35).
  • After (this PR's head; the same on f52620c): the card reads "News's agent asks (for you) · in News's conversation", the panel "? News's agent asks (for you): …", the sheet "Asked by Calendar's agent for you", and the toast "Calendar's agent for you asks. Open the sheet to approve or deny." (frames 22, 34). The system agent's lane still reads "(for the assistant)" (frame 24).
  • Harness note: on this main, System apps: every one has its own agent that can notify #274 gave Photos an agent, so the harness now uses AI providers as its app without one (S2). Its S9 step presses the switch on the third agent row in Settings, which is now Maps's rather than News's, so S9 fails on main and on every branch alike.

Overlap. This branch is on main 4f73ab3, after #272, #273 and #274 merged; the rebase had no conflicts. The open #255 edits approvals/sheet.rs in other hunks, and #230 does not touch these files; both merge with this branch cleanly. The four fixes from the same run are independent, and each pair merges without conflicts: this one, #279, #281 and #282.

🤖 Generated with Claude Code

…ient id

The "Ask <app>" panel opens the app's conversation as the client instance
"shell-ask" (app_chat::INSTANCE), and that id reached the person: the
question card's "News's agent asks (shell-ask)", the sheet's "Asked by
Calendar's agent for shell-ask" and its toast "Calendar's agent for
shell-ask asks" (instrument run, frames 22 and 35). Request::asked_by and
approvals::sheet::caller_label printed any client as given.

A turn from one of the shell's own surfaces where the person talks to an
app's agent is the person's, so those labels now say so, beside the
existing "(for the assistant)" of the system agent's lane: "News's agent
asks (for you)", "Asked by Calendar's agent for you", "Calendar's agent
for you asks". approvals::sheet::persons_surface knows the two surfaces:
the panel and a card's in-card chat (glance_chat::INSTANCE, "card-chat",
the same leak). Any other client keeps the name it gave ("Rinx's agent for
weather"). The audit keeps the raw caller.

Tests: approvals (the caller label, the sheet line and its notice) and
questions (asked_by on each surface).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ymote
ymote force-pushed the fix/no-client-id-in-prompts branch from 75a2bf3 to 20a62cb Compare October 2, 2026 18:26
@ymote

ymote commented Oct 2, 2026

Copy link
Copy Markdown
Contributor Author

Local CI passed on 20a62cb (tools/ci-local.sh --only all --linux-host, 15m46s, Darwin arm64; the ubuntu jobs on the Linux build host, Linux x86_64).

GitHub would run for this PR: desktop.yml, phone.yml, apps.yml. Merged on this local pass (macOS runner queue); GitHub CI runs on the merge commit on main.

Job Step Result Time
ci-local / drift The local mapping fits the workflows PASS -
desktop.yml / desktop Prepare the pinned framework sources PASS 1s
desktop.yml / desktop Compile the desktop with the shared runtime PASS 1m44s
desktop.yml / desktop One copy of every shell source PASS -
desktop.yml / desktop Desktop tools and scripts PASS 7s
desktop.yml / desktop One Makepad, App Hub, octos and Rinx in the locked graph PASS 1s
desktop.yml / desktop The native apps' generated places match native-apps.json PASS 0s
phone.yml / home Prepare pinned sources and the reviewed runtime patch PASS 0s
phone.yml / home Compile Home and its bundled modules PASS 1m25s
phone.yml / home Verify the single runtime graph PASS 1s
phone.yml / home The native apps' generated places match native-apps.json PASS -
phone.yml / home The pinned octos revision PASS -
phone.yml / home Build octos (unless cached) PASS -
phone.yml / home Build Home, App Hub admission and runtime policy tests PASS 2m13s
phone.yml / home Test Home, App Hub admission and runtime policy PASS 6m32s
phone.yml / home Two-lane scenario (real kernel, scripted model) PASS 29s
apps.yml / services (linux) python3 tools/setup.py PASS 0s
apps.yml / services (linux) Kernel service PASS 10s
apps.yml / services (linux) App peers PASS 23s
apps.yml / services (linux) AI providers config PASS 3s
apps.yml / services (linux) L0 in-card chat (sys.chat, host side) PASS 8s
apps.yml / services (linux) System toolbox (workflow templates) PASS 1m28s
apps.yml / kernel-security (linux) python3 tools/setup.py PASS 0s
apps.yml / kernel-security (linux) The pinned octos revision PASS -
apps.yml / kernel-security (linux) Build octos (unless cached) PASS -
apps.yml / kernel-security (linux) Real-kernel tests PASS 31s
apps.yml / apps python3 tools/setup.py PASS 0s
apps.yml / apps Host services (Mail, AI providers, News) PASS 1m00s
apps.yml / apps Shell AI services (crates/ai-host) PASS 1m46s
apps.yml / apps AppCard runtime setup safeguards PASS 0s
apps.yml / apps AppCard clippy (own crates; shared runtime compiles) PASS 12s
apps.yml / apps AppCard transport and store PASS 11s
apps.yml / apps One Makepad, App Hub, octos and Rinx in the locked graph PASS 2s
rom.yml / product (linux) python3 -m unittest discover -s tests -v SKIPPED (!) -
rom.yml / product (linux) Check generated Agent Binder client SKIPPED (!) -
rom.yml / product (linux) bash -n scripts/stage-forks.sh scripts/publish-release.sh scripts/apply-to-tree.sh scripts/build-rom.sh PASS -
rom.yml / web-installer (linux) npm ci --ignore-scripts --no-audit --no-fund SKIPPED (!) -
rom.yml / web-installer (linux) npm test SKIPPED (!) -
rom.yml / web-installer (linux) npx playwright install --with-deps chromium SKIPPED (!) -
rom.yml / web-installer (linux) npm run test:browser SKIPPED (!) -
rom.yml / web-installer (linux) python3 -m unittest discover -s tests -p test_installer_manifest.py -v SKIPPED (!) -
rom.yml / web-installer (linux) bash -n scripts/release.sh SKIPPED (!) -
linux-host / sandbox (linux) python3 tools/setup.py PASS 0s
linux-host / sandbox (linux) Process sandbox on Linux (Landlock, seccomp) PASS 1m16s

Skipped (these did NOT pass; (!) marks a skip that blocks tools/ci-local-merge.sh):

  • rom.yml / product (linux): python3 -m unittest discover -s tests -v: javac -version does not work here: install a JDK (17 or newer) and put its bin/ on PATH or set JAVA_HOME
  • rom.yml / product (linux): Check generated Agent Binder client: needs build-tools/35.0.0/aidl, platforms/android-35/framework.aidl in the Android SDK (no Android SDK found): install the SDK packages 'build-tools;35.0.0' and 'platforms;android-35' (sdkmanager) and set ANDROID_HOME
  • rom.yml / web-installer (linux): npm ci --ignore-scripts --no-audit --no-fund: no node, npm, npx on PATH (the workflow uses node 24); put node on PATH
  • rom.yml / web-installer (linux): npm test: no node, npm, npx on PATH (the workflow uses node 24); put node on PATH
  • rom.yml / web-installer (linux): npx playwright install --with-deps chromium: no node, npm, npx on PATH (the workflow uses node 24); put node on PATH
  • rom.yml / web-installer (linux): npm run test:browser: no node, npm, npx on PATH (the workflow uses node 24); put node on PATH
  • rom.yml / web-installer (linux): python3 -m unittest discover -s tests -p test_installer_manifest.py -v: no node, npm, npx on PATH (the workflow uses node 24); put node on PATH
  • rom.yml / web-installer (linux): bash -n scripts/release.sh: no node, npm, npx on PATH (the workflow uses node 24); put node on PATH

Notes:

  • GitHub runs Python 3.12; this run used Python 3.9.6
  • GitHub runs Python 3.12; the Linux host used Python 3.14.4

@ymote
ymote merged commit 8e65d5c into main Oct 2, 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