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
fix(relay): report pre-delivery native failures as refused instead of native_outcome_unknown #176
The relay native worker reports failures that happen before any native delivery as native_outcome_unknown. In the RC4 validation campaign (#164, first run), five macOS Codex submissions returned native_outcome_unknown. The actual cause was that the receiver's launchd PATH did not contain the codex executable: nothing was delivered, but the result looked ambiguous and the cause was invisible.
Current behavior
session_peer_relay/worker.py sets attempted = True after validate_send and before LocalTransport().execute(...). Any CcPeerError raised inside execute is mapped to native_outcome_unknown, including errors such as "Codex executable not found" that occur before submission.
session_peer_relay/native.py runs the worker with stderr=DEVNULL, and a non-zero exit, invalid output or timeout also becomes native_outcome_unknown, so no cause class survives.
Reproduction: run a macOS receiver under a minimal service PATH (/usr/bin:/bin:/usr/sbin:/sbin) with a Codex binding and send to it. The sender gets status: unknown, native_outcome_unknown. A dry-run under the same environment reports Codex executable not found.
Proposal
Split the native path into a pre-submission phase (executable resolution, home/writer validation, target resolution) and the submission phase. Report pre-submission failures as status: refused with a fixed, allowlisted reason (for example codex_executable_not_found), because nothing reached the target.
Keep unknown and retryAllowed: false only when the submission may have started. No resend semantics change.
Never expose raw native error text or paths; use codes only.
Acceptance
Tests: missing executable → refused plus the specific reason and no submission; a failure after submission starts → still unknown; worker crash or timeout → still unknown.
Relay sender output and receiver diagnostics show the reason class without paths or message content.
Activity
docs: require the Codex executable on macOS/Linux receiver service PA…