Yeachan-Heo/oh-my-codex · error · Error
shutdown_${scope}_HUD_pane_pid_missing:${effectiveHudPaneId}
Error message
shutdown_${scope}_HUD_pane_pid_missing:${effectiveHudPaneId} What it means
Thrown when the persisted HUD pane id matches the effective HUD pane id but the persisted HUD pane PID is missing or invalid. Shutdown refuses to proceed without a verifiable PID for the pinned HUD pane.
Source
Thrown at src/team/runtime.ts:5224
}
const owner = readPaneTeamOwnerTagResult(authorization.paneId);
if (owner.status === 'error') {
throw new Error(`shutdown_${scope}_${kind.replaceAll(' ', '_')}_owner_unavailable:${authorization.paneId}:${owner.error}`);
}
const currentOwner = owner.status === 'value' ? owner.value : null;
if (currentOwner !== authorization.owner) {
throw new Error(`shutdown_${scope}_${kind.replaceAll(' ', '_')}_owner_changed:${authorization.paneId}`);
}
};
const persistedHudPaneId = typeof hudPaneId === 'string' && /^%[0-9]+$/.test(hudPaneId)
? hudPaneId
: null;
const persistedLeaderPaneId = typeof leaderPaneId === 'string' && /^%[0-9]+$/.test(leaderPaneId)
? leaderPaneId
: null;
if (persistedHudPaneId && effectiveHudPaneId === persistedHudPaneId && (typeof hudPanePid !== 'number' || !Number.isSafeInteger(hudPanePid) || hudPanePid <= 0)) {
const scope = sharedSessionTopology ? 'shared_session' : 'detached_session';
throw new Error(`shutdown_${scope}_HUD_pane_pid_missing:${effectiveHudPaneId}`);
}
const frozenHudAuthorization = effectiveHudPaneId
? (sharedSessionTopology
? freezeSharedPaneAuthorization(
effectiveHudPaneId,
'HUD pane',
effectiveHudPaneId === persistedHudPaneId ? hudPanePid : undefined,
)
: (() => {
if (!persistedHudPaneId || effectiveHudPaneId !== persistedHudPaneId || !tmuxPaneOwnerId
|| typeof hudPanePid !== 'number' || !Number.isSafeInteger(hudPanePid) || hudPanePid <= 0) {
throw new Error(`shutdown_detached_session_HUD_pane_authorization_unavailable:${effectiveHudPaneId}`);
}
const proof = readExactPaneProofSync(effectiveHudPaneId);
if (proof.status !== 'live' || proof.pid !== hudPanePid) {
throw new Error(`shutdown_detached_session_HUD_pane_identity_changed:${effectiveHudPaneId}`);
}
const owner = readPaneTeamOwnerTagResult(proof.paneId);View on GitHub (pinned to 3ad79a8a6f)
Solutions
- Restore or recompute hud_pane_pid in the persisted config (or clear hud_pane_id so the pin is dropped)
- Regenerate the team config by restarting the team session cleanly
- Add a config sanitization step on startup
Example fix
// before
shutdown({ hudPaneId: cfg.hud_pane_id, hudPanePid: cfg.hud_pane_pid });
// after
const pin = cfg.hud_pane_pid && Number.isSafeInteger(cfg.hud_pane_pid) && cfg.hud_pane_pid > 0;
shutdown({ hudPaneId: pin ? cfg.hud_pane_id : undefined, hudPanePid: pin ? cfg.hud_pane_pid : undefined }); Defensive patterns
Strategy: validation
Validate before calling
const pin = Number.isSafeInteger(hudPanePid) && hudPanePid > 0; call(pin ? {hudPaneId, hudPanePid} : {}); Type guard
const isValidPanePid = (p: unknown): p is number => typeof p === 'number' && Number.isSafeInteger(p) && p > 0;
Prevention
- Sanitize persisted pid fields on load
- Clear pane pins after crashes
When it happens
Trigger: effectiveHudPaneId === persistedHudPaneId while hudPanePid is not a number, not a safe integer, or <= 0 at the top of the shutdown flow.
Common situations: Config migrated or hand-edited losing hud_pane_pid; older version wrote null; partial config write after a crash.
Related errors
- startup_worker_pane_pid_unavailable:${paneId}
- shutdown_shared_session_${kind.replaceAll(' ', '_')}_pid_mis
- tmux target validation failed: ${resolved.reason}
- startup_cleanup_pane_owner_unavailable:missing_team_owner_id
- startup_cleanup_pane_target_invalid:${cleanupPane.pane_id}
AI-assisted analysis of Yeachan-Heo/oh-my-codex@3ad79a8a6f (2026-08-27).
Data as JSON: /api/errors/112224b37c7df6b2.
Report an issue: GitHub.