You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
provider proxies keep session state in the repo tree (bin/sessions.json) — move to ~/.local/state #3067
The local provider proxies (bin/commandcode-proxy.mjs, bin/codex-proxy.mjs, bin/claude-code-proxy.mjs) read/write their session-affinity map at bin/sessions.json — inside the tracked repo tree, next to the scripts.
Verified 2026-10-31: the file holds OpenCode session ids (ses_…) mapped to upstream session state, and it is LIVE — modified 08:16 CDT today by this morning's OpenChamber scheduled-lane runs going through the proxies.
Problems:
The laptop primary clone (~/git/code) is permanently dirty, so pm-git-sync refuses to ff-pull it (on-main + clean rule) — the primary silently falls behind origin/main. This bit the 2026-10-31 OpenClaw route-only deploy (PR openclaw: route models only through the opencode-route door #3065), which had to deploy from a clean worktree instead.
Runtime state does not belong in a tracked tree — precedent: pm-aggregator's runtime state was moved to ~/.local/state/pm-aggregator/ on 2026-10-27 for exactly this reason.
Fix: point the proxies' session-state path at ~/.local/state//sessions.json (env-overridable, default out-of-tree), migrate the live file once, and drop bin/sessions.json from the tree (gitignore the path defensively so a regression cannot re-dirty the primary).
Scope correction (2026-10-31, after Drew's question): yesterday's move DID happen — PRs #2782/#2784 moved the proxies' WORKDIR state (bin/work/: warm-sessions.json, sessions/, acp-project) to ~/.local/state/cli-proxies. bin/sessions.json is a different path and was MISSED by that fix:
bin/commandcode-proxy.mjs:428 — SESSION_FILE = path.join(PROXY_DIR, 'sessions.json'), anchored to the script's own directory, no env override.
bin/claude-code-proxy.mjs:52 — SESSION_FILE = env CLAUDE_CODE_PROXY_SESSION_FILE || path.join(PROXY_DIR, 'sessions.json'); the override exists but no unit sets it, so it defaults into bin/ too. (The two proxies share this file / mirrored key space, so the fix must land both on the SAME new path.)
bin/muse-proxy.mjs — warm-sessions.json resolves under WORKDIR; that one moved correctly.
bin/codex-proxy.mjs — sessions.json resolves via sessionStateDir(); audit in the fix.
Fix in flight: env-overridable session-file path for commandcode-proxy mirroring claude-code's, both units pointed at ~/.local/state/cli-proxies/sessions.json in home/common/default.nix, live file migrated on deploy.
Correction per Drew (2026-10-31): do NOT gitignore the old bin/sessions.json path. After the fix nothing may write there at all — a gitignore would mask a regression. The dirty primary is the tripwire: if bin/sessions.json ever reappears as dirt, that is the signal the fix leaked. (Same reasoning as Drew's 2026-10-29 call on the bin/work residue: moved intact, deliberately not gitignored.) The fix is: env-overridable session-file paths + both proxy units pointed at ~/.local/state/cli-proxies/sessions.json + one-time migration of the live file. Nothing else.
Activity
dezren39 commentedon Oct 31, 2026
Scope correction (2026-10-31, after Drew's question): yesterday's move DID happen — PRs #2782/#2784 moved the proxies' WORKDIR state (bin/work/: warm-sessions.json, sessions/, acp-project) to ~/.local/state/cli-proxies. bin/sessions.json is a different path and was MISSED by that fix:
Fix in flight: env-overridable session-file path for commandcode-proxy mirroring claude-code's, both units pointed at ~/.local/state/cli-proxies/sessions.json in home/common/default.nix, live file migrated on deploy.
dezren39 commentedon Oct 31, 2026
Correction per Drew (2026-10-31): do NOT gitignore the old bin/sessions.json path. After the fix nothing may write there at all — a gitignore would mask a regression. The dirty primary is the tripwire: if bin/sessions.json ever reappears as dirt, that is the signal the fix leaked. (Same reasoning as Drew's 2026-10-29 call on the bin/work residue: moved intact, deliberately not gitignored.) The fix is: env-overridable session-file paths + both proxy units pointed at ~/.local/state/cli-proxies/sessions.json + one-time migration of the live file. Nothing else.
fix(proxies): move shared sessions.json to ~/.local/state/cli-proxies (…
Merge pull request #3072 from developing-today/fix/proxy-sessions-sta…
dezren39 commentedon Oct 31, 2026
🤖 Agent note · done
chore(bin): remove tracked sessions.json — proxy session state lives …