Repository navigation
Description
Environment
- Orca 1.4.199 (app bundle); terminal daemon still running 1.4.197
- macOS 26.6.2 (25G83), Apple Silicon
- Electron 43.6.0 on disk; processes left from the previous launch still report 43.4.1
Related issues
- [Bug]: Processes spawned in Orca get EPERM on ~/Documents while ~/Desktop and ~/Downloads work #17600 — same user-visible symptom (EPERM on
~/Documentsfor Orca-spawned processes,
appearing mid-session with no permission change on the user's side). The mechanism below is
a likely explanation for it. - macOS terminal cwd becomes unreadable when app and daemon versions are mismatched #17696 — same symptom reported as an unreadable cwd while app and daemon versions are
mismatched. - Session daemon never auto-updates for users with live terminals — silent, unbounded version drift (daemon 1.4.190 vs app 1.4.197) #18831 — covers the live-session veto in the stale-bundle replacement path, which is
point (c) below. This report adds the TCC-severing mechanism and a separate defect in the
severedcheck itself. - macOS TCC grants (Full Disk Access / Desktop) keep getting invalidated after Orca updates — child processes hit EPERM mid-session #13921 — possibly related. That report says toggling the grant off and on restores
access without an app restart, which does not obviously fit the mechanism described here,
so it may be a different failure mode.
Symptom
In any Orca terminal:
$ cd ~/Documents/<any-project>
$ ls
ls: .: Operation not permitted
shell-init: error retrieving current directory: getcwd: cannot access parent directories: Operation not permitted
job-working-directory: error retrieving current directory: getcwd: cannot access parent directories: Operation not permitted
Only TCC-protected locations are affected (~/Documents, ~/Desktop, ~/Downloads).
Work under ~/orca/workspaces keeps working, which makes the failure look arbitrary.
Orca itself holds the grant, so this is not a missing permission:
$ sqlite3 ~/Library/Application\ Support/com.apple.TCC/TCC.db \
"select service,client,auth_value from access where client='com.stablyai.orca';"
kTCCServiceSystemPolicyDocumentsFolder|com.stablyai.orca|2
kTCCServiceSystemPolicyDesktopFolder|com.stablyai.orca|2
kTCCServiceSystemPolicyDownloadsFolder|com.stablyai.orca|2
Root cause
The terminal daemon outlives the app bundle it was exec'd from.
1. The daemon is designed to survive app restarts.
/Applications/Orca.app/Contents/Frameworks/Orca Helper.app/Contents/MacOS/Orca Helper
.../out/main/daemon-entry.js
--socket .../daemon/daemon-v36.sock
--app-version 1.4.197
--spawner-exec-path /Applications/Orca.app/Contents/MacOS/Orca
--login-session-watch
2. ShipIt installs an update by renaming the running bundle out of /Applications.
2026-09-09 13:25:36 Moving bundle from file:///Applications/Orca.app/
to file:///var/folders/.../T/com.stablyai.orca.ShipIt.wvfvUsm4/Orca.app
3. The rename alone is harmless. tccd can still read and validate the bundle at its new
location, so the daemon kept working for another day. Verified from session transcripts:
terminal sessions read ~/Documents successfully at 09-09 19:22, 09-09 20:07 and 09-10 10:07,
all after the rename.
4. The next update removes the previously parked copy, and the daemon's executable
becomes unlinked:
$ lsof -p 3337 | awk '$4=="txt"'
.../T/com.stablyai.orca.ShipIt.wvfvUsm4/Orca.app/Contents/Frameworks/Orca Helper.app/Contents/MacOS/Orca Helper
$ ls -d /private/var/folders/.../T/com.stablyai.orca.ShipIt.*
...ShipIt.BlUZRM0f ...ShipIt.eiX9vreI # wvfvUsm4 is gone
$ codesign -vvv +3337
+3337: host has no guest with the requested attributes
5. tccd can no longer resolve the daemon's code identity, so the accessor falls back to
the shell binary itself:
tccd: Platform binary prompting is 'Deny' because: is Platform Binary
/bin/zsh is an Apple platform binary, so the request is denied without a prompt. Every
shell spawned by the daemon loses access, including ones spawned through orca-tcc-login.
Why the existing guards did not catch it
The main bundle already contains replaceSeveredMacTccDaemonBeforeNewPty() and
replaceStaleBundleDaemonOnce(), with reason codes severed_tcc_attribution,
stale_bundle and different_app_path. None of them fired. The daemon's own identity
record shows why:
// ~/Library/Application Support/orca/daemon/daemon-v36.pid
{
"pid": 3337,
"appVersion": "1.4.197",
"entryPath": "/Applications/Orca.app/Contents/Resources/app.asar.unpacked/out/main/daemon-entry.js",
"spawnerExecPath": "/Applications/Orca.app/Contents/MacOS/Orca"
}(a) The severed check inspects the wrong path.
i.spawnerExecPath ? (existsSync(i.spawnerExecPath) ? `intact` : `severed`) : `unknown`spawnerExecPath is /Applications/Orca.app/Contents/MacOS/Orca. An in-place update
removes and recreates that path, so existsSync is true and the check returns intact.
The path that actually got severed is the daemon's own executable, which is never
inspected.
(b) The entryPath check compares strings that never change. entryPath is identical
across versions, so the comparison returns match.
(c) The appVersion check is correct but suppressed. The comparison of 1.4.197 against
1.4.199 correctly returns true, but replacement is then abandoned:
let n = await this.getDaemonLiveSessionCount(),
r = Math.max(this.activeSessionIds.size, n ?? 0);
if (n === null || r > 0) {
console.warn(`[daemon] Packaged daemon is stale - preserving it because live…`);
return;
}Replacement only proceeds when the live session count is zero. On a machine that keeps
agents running this is effectively never true. In this instance the daemon owned 123
descendant processes: 43 login sessions, 45 shells and 20 live claude sessions, four
of which have their working directory inside ~/Documents and are therefore unusable.
The daemon is preserved in a permanently broken state.
(d) Nothing tells the user. The warning is console.warn only. It appears in neither
~/Library/Application Support/orca/logs/daemon.log nor main.trace.ndjson (grep for
severed, stale and attribution returns zero hits in both), and there is no UI
indication. From the user's side the terminal simply stops being able to read
~/Documents, with nothing pointing at the daemon.
Reproduction
- Launch Orca and open terminals; keep at least one session alive.
- Let an auto-update install. The running bundle is parked under
$TMPDIR/com.stablyai.orca.ShipIt.<rand>/. - Let a second auto-update install, which removes the first parked copy.
- In any Orca terminal, run
ls ~/Documents.
Expected: a directory listing.
Actual: ls: .: Operation not permitted, plus shell-init: error retrieving current directory: getcwd: ... from any bash that starts in that directory.
This is not a one-off. The same failure was recorded on this machine on 2026-08-10
(update at 07:53, first permission errors at 19:03), so it recurs whenever a daemon
spans two updates.
Suggested fixes
1. Base the severed check on the daemon's own executable. Compare
proc_pidpath(daemonPid) against the current bundle and verify that path still exists, or
run a code-signature validity check against the running pid. That is the condition which
actually predicts the TCC failure; spawnerExecPath does not.
2. When automatic replacement is declined, surface it. A banner along the lines of
"The terminal daemon is running from a removed app bundle, so Documents, Desktop and
Downloads are blocked. Restart it?" with a one-click restart would turn a multi-hour
diagnosis into a click. Listing the affected sessions first would let the user save work.
3. Consider preserving sessions across the replacement. Passing the pty master
descriptors to the new daemon over SCM_RIGHTS before the old one exits would keep running
shells alive; they reparent to launchd while the ptys stay open. Node has no built-in API
for this, so it needs a native addon. Note this preserves the processes but not their TCC
attribution, which is fixed at exec time, so only newly spawned terminals would regain
access.
4. Smaller mitigation. Do not let ShipIt remove a parked bundle while a live process
still holds its executable open.
Workaround for affected users
Restart the daemon, accepting the loss of every terminal session:
# identify Orca processes running from a removed bundle
for p in $(pgrep -f Orca); do
t=$(lsof -p "$p" 2>/dev/null | awk '$4=="txt"{print $NF; exit}')
case "$t" in *ShipIt*) echo "stale pid=$p $t";; esac
done
kill <daemon-pid>Record the working directory and session id of every running agent first, since they have
to be resumed by hand afterwards. Keeping projects outside ~/Documents, ~/Desktop and
~/Downloads avoids the failure entirely.
Activity
fix(daemon): inspect running process to detect severed macOS TCC attr…
tim-brand commentedon Sep 11, 2026
Adding a Local Network variant of this, observed on Orca 1.4.200 / macOS 26.5.2 (Apple Silicon).
Symptom: in an Orca terminal, non-Apple binaries (node, terraform) got
EHOSTUNREACHto a LAN host while/usr/bin/curlto the same address returned 200. The kernel'stcp_connection_summaryshowed the node socket inSYN_SENTwith 0 SYNs out. Same as #18900.Mechanism matches this issue: the terminal daemon (
Orca Helper, ppid 1) had outlived an update and was executing from$TMPDIR/com.stablyai.orca.ShipIt.*/Orca.app/...; the new main app and four fresh helpers were running from/Applications. Sessions under the fresh helpers reached the LAN fine.One difference from the TCC case in this report: for Local Network a single update was enough. The parked ShipIt copy still existed and the daemon's executable was intact, so the "rename alone is harmless" observation does not hold for the NECP/Local Network check.
/Library/Preferences/com.apple.networkextension.uuidcache.plistonly listed the new bundle's Mach-O UUIDs, and the store recorded no Local Network decision forcom.stablyai.orcaor.helper, so the surviving daemon's identity no longer matched any grant.Suggested fix 1 (check the daemon's own executable / code identity) would have caught this too. Restarting the daemon resolved it.
fix(daemon): avoid caching settled intact attribution across sequenti…
WeZZard commentedon Sep 20, 2026
I encountered this issue today when onboarding. I'm a newcomer to this app.
smabe commentedon Sep 26, 2026
Confirming the Local Network variant on Orca 1.4.212 / macOS 27.0 (26A428), Apple Silicon.
Symptom: in an Orca terminal, Homebrew Python got
[Errno 65] No route to hostto a LAN host, while/usr/bin/curlandsshto the same address worked. This has recurred after several Orca updates.Mechanism is the same as described above. The terminal daemon (
Orca Helper … daemon-entry.js --socket …/daemon/daemon-v36.sock, ppid 1) started two days before the current app launch, and every terminal shell descends from it.lsof -p <daemon pid>shows itstxtimages under the parked update copy:One difference from the previous comment: that
ShipIt.nWAGqdUXdirectory no longer exists, so the daemon is running from deleted executables. Quitting and relaunching Orca did not help, because the new app reattaches to the surviving daemon. Workarounds that do work are an SSH local forward (ssh is exempt, and loopback is not restricted) or killingdaemon-entry.jsand relaunching.A check of the daemon's own executable or code identity (suggested fix 1) would catch this too.
fix(daemon): judge severed macOS TCC attribution by the daemon's own …
Jinwoo-H commentedon Oct 6, 2026
Help us confirm the cause (read-only, no sudo, ~1 minute)
If your Orca terminals are refused access to Documents, Desktop or Downloads right now, before you restart or toggle anything, could you run these in a normal Terminal.app window (not Orca) and paste the output? Please redact your username if you like.
A fix that keeps terminal permissions across updates is in review in #25848. This data tells us whether it covers your case.
RainofTerra commentedon Oct 9, 2026
Data for the request above, captured while the failure was live. This is the
Local Network variant: no Documents/Desktop denial was observed.
Versions / timing: macOS 27.0.1 (26A434), Apple Silicon. Orca updated
1.4.220 → 1.4.223 at 12:08:05 local. The Mac did not sleep between the update
and the failure; the last sleep/wake was about an hour before the update.
Notable: one update was enough. The old daemon was launched on Oct 5 at
16:12 from a freshly installed 1.4.220 (the Mac rebooted after that install),
and the ShipIt log shows no further install until 12:08 today. That single update
moved its bundle to
ShipIt.QviHWGrU. By 12:10 the directory was gone, withthe old daemon still running from it.
1. Old daemon running from the moved-aside bundle
Before the update, the old daemon (2497,
daemon-v39.sock,--app-version 1.4.220)was a child of the 1.4.220 app process (2384). After the update it was
reparented to launchd and kept all 19 pre-update shells. The new app started a
second daemon (47772,
daemon-v41.sock, 1.4.223, in/Applications,codesign -vvalid).The old daemon's loaded images have the same Mach-O UUIDs as the installed
1.4.223 bundle (
Orca Helper…E512E9BEF537, Electron Framework 43.7.5…EA18B13C1415). So this is not the Electron-changing-update case: the code is
identical, and only the path and the responsible process are gone.
2. tccd: nothing relevant in the suggested grep. That's expected, because
Local Network is decided on the network-extension side, not by tccd. These are
the lines that settle it, logged by
UserEventAgentundercom.apple.networkextensionat each refused connect from a shell under the olddaemon:
2384 is the 1.4.220
Orcamain process that spawned the daemon, and it exitedfor the update.
launchctl procinfo(as root) doesn't report 2384 for anythingon the old side. Every process there reports itself as responsible, while the
new side resolves to the live app:
loginfor a shell)loginfor a shell)responsible pathis/Applications/Orca.app/Contents/MacOS/Orcain all four.On the old side, a unique pid equal to the pid looks like a fallback rather than
a real value. A shell under the new daemon makes the same connection with no
UserEventAgentlines logged at all.3. Copies of Orca: only
/Applications/Orca.app.4. Controlled comparison: the same command to the same LAN host, 16 s apart:
/usr/bin/nc -zto the same address:port succeeded from the old daemon's shell.ShipIt log for the update (
~/Library/Caches/com.stablyai.orca.ShipIt/ShipIt_stderr.log):The log has no line for removing
QviHWGrU, so I can't say what deleted it orexactly when.
AmethystLiang commentedon Oct 9, 2026
@Jinwoo-H is looking at this
tim-brand commentedon Oct 10, 2026
Let me add the result of the commands on my side as well:
Running version 1.4.222, not sure from what version I updated.
tim-brand commentedon Oct 10, 2026
Tested another update run:
Output of the commands after the failed connection error:
minutimes commentedon Oct 18, 2026
Additional field evidence on official macOS 1.4.229: the signed host fix is installed, but existing terminals remain on an update-severed legacy host.
Observed October 18–19 on macOS 26.3, Apple Silicon:
Limits: a deleted executable alone does not prove TCC denial, as your signed investigation notes. We did not obtain an exact TCC-request correlation for each failed historical child. The generation split, missing image and false-intact check were verified separately.
Please address the remaining legacy recovery gap alongside #21826 and #27021: show actual per-host generation/access health and provide preserve-and-resume/drain for old sessions. Updating the app alone leaves them on the old host; a blanket restart risks unrelated live work. Confirm zero required consumers before retiring the old generation.
This report omits private project paths, account IDs, credentials, raw logs and screenshots.
Recovery outcome (October 19, after the observations above):
This strengthens the runtime-specific evidence while retaining the TCC-correlation limits stated above.
saik003 commentedon Nov 9, 2026
Another data point on 1.4.240, macOS 15.7.9 (Intel), without any update in between:
orca-terminal-host(same 1.4.240 bundle, signed6CX3WHS9HZ) started Oct 26 and stayed detached.terminal-host-<hash>dir, whose directory was recreated at that moment, while the Oct 26 host was still alive.can't read the current directory (EPERM)in a worktree under~/orca/workspaces/...(not~/Documents). Retiring the old host fixed it.So relaunching with the same version is enough to sever the long-lived host. This matters on machines nobody sits in front of: a relaunch silently breaks every terminal-spawned agent until someone kills the old host by hand. A health check on relaunch that drains/retires a host whose bundle was rewritten under it would cover this.
yaohao159123 commentedon Nov 29, 2026
Another data point on 1.4.281, macOS 27.2.1 (26B131), Apple Silicon, always-on machine: each update leaves a new
terminal-host-<hash>and macOS asks for permissions again.~/Library/Application Support/orca/daemon-host/macos/now has fiveterminal-host-<hash>dirs, created Nov 19, 20, 22, 23 and 29: one per update. Live agent processes run from the newest one:.../terminal-host-6b92ea…/app.noindex/Orca Agents.app(com.stablyai.orca, team6CX3WHS9HZ).UserNotificationCentersendAction:) answered at 14:50, two minutes later. I couldn't tell from the log which service it was for.osascript→ System Events (UI scripting another app).System EventsloggedTCCAccessRequestIndirectwith targetOrca Agents.app(19 times between 19:52 and 20:03), and two more consent dialogs were answered at 19:56 and 19:59.From the user's side: on a machine that updates Orca often, macOS asks again for permissions it already granted, whenever agents touch anything TCC-protected. A host path that stays the same across updates, or a host whose TCC identity carries over, would stop this. Happy to send more logs.