Repository navigation
FIX: honour Codex 0.170 reply display instructions in Sessions - #110
Merged
Merged
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
Approval is blocked by an active history-revocation bug that can leave stale plaintext replies accessible, along with an untranslated UI notice in non-English sessions.
2 open issues
What changed in this PR
This pull request adds Codex 0.170 answer-display handling across Sessions live updates, history, rollouts, reconnects, clipboard content, and read-only web projections, replacing restricted or unsupported replies with a safe notice while preserving ordinary streaming and usage accounting.
Changes:
- Parses and propagates display decisions across daemon events, native history, local and compressed rollouts, reconnects, and cached UI state.
- Adds regression coverage for replay, truncation, Guardian reviews, native compatibility, and browser projections.
- Updates README documentation and the pinned slash-command audit for Codex 0.170.0.
| File | Description |
|---|---|
| README.md | Documents restricted-reply behavior and adds Codex 0.170 native-test instructions. |
| internal/web/control_test.go | Verifies restricted replies are absent from serialized read-only browser state. |
| internal/ui/monitor_history.go | Propagates reply restrictions through cached, pinned, and refreshed monitor history. |
| internal/ui/monitor_history_test.go | Tests clipboard and live-mirror redaction after history restrictions. |
| internal/ui/model.go | Preserves reply-protection decisions when applying live monitor observations. |
| internal/codex/session_history.go | Applies display restrictions to bounded history results and local mirrors. |
| internal/codex/session_history_unix.go | Reads moderation metadata from native bounded-history responses. |
| internal/codex/session_history_unix_test.go | Tests history restrictions surviving disconnects and replay. |
| internal/codex/session_context.go | Parses rollout moderation events and prevents unsafe truncated-tail recovery. |
| internal/codex/session_context_daemon.go | Tracks display restrictions across live item, delta, and turn notifications. |
| internal/codex/live_usage.go | Carries answer guards across daemon snapshots, reconnects, and rollout replacement. |
| internal/codex/live_usage_guardian_test.go | Covers Guardian thread reuse and quota accounting across reconnects. |
| internal/codex/live_usage_compressed.go | Preserves answer-protection state for compressed rollout histories. |
| internal/codex/daemon_status.go | Adds answer guards to daemon snapshots. |
| internal/codex/daemon_status_unix.go | Exports per-thread answer guards from native daemon state. |
| internal/codex/daemon_native_unix_test.go | Adds Codex 0.170 native socket compatibility coverage. |
| internal/codex/answer_display.go | Implements display-decision parsing, answer guards, and the fallback notice. |
| internal/codex/answer_display_test.go | Tests display decisions, replay protection, truncation, and restart behavior. |
| docs/slash-command-support.md | Updates the pinned upstream slash-command audit to Codex 0.170.0. |
Review effort: Lite
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Why
Codex 0.170.0 can deliver the original answer text alongside instructions to hide, block or specially present it. Reading only the text can expose it in a Sessions preview, copied answer or read-only browser response. This PR handles that contract without raising the minimum supported Codex version.
Changes
Verification
Codex 0.170.0 release · Answer display contract · Guardian history reuse