Repository navigation
feat(logs): index scan sessions and optionally retain rollout events - #278
2830500285 wants to merge 34 commits into
Conversation
|
Thanks for putting this together. One interaction to watch: the new |
|
The conflicts are resolved against the current archived-worker and compressed-session behavior. The rollout export remains opt-in and bounded to the invocation. The follow-up removes the wrapper-only metadata caps and keeps the retention option out of reusable workflow identity. All 76 workflow, rollout, navigation, and scan-log tests passed. The full CI run passed. I published the maintainer branch in this repository. From the PR branch, you can apply the tested commit with git fetch https://github.com/openai/codex-security.git maintainer-sync/pr-278
git merge --ff-only FETCH_HEAD@codex review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 02b88eac84
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
This PR branch now contains the tested merge with main, published by fast-forward. @codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8b8d98b119
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2dfad7af8e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
mldangelo-oai
left a comment
There was a problem hiding this comment.
Please hold this PR before merging. The rollout exporter can write the old scan’s index or retained events into a replacement output directory. The fix needs to preserve the original directory identity throughout publication and cleanup. The green CI run does not exercise this interleaving.
|
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: cd9cb23a57
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b8e1114884
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 09e702e53f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
(cherry picked from commit 5ce7e7c)
Summary
Fixes #187. Local scans can finish or stop after starting several native sessions. A private index in the scan directory records the threads and their relationships before the temporary Codex home is removed.
Changes
artifacts/rollout-sessions/index.json. The SDK and CLI can locate it for completed, failed or interrupted local scans. Existing scan histories require no migration.--retain-rollout-sessionsopts a scan, bulk run, rerun or resume into retaining attributable JSONL events. Reruns and resumes need their own opt-in. The archive uses immutable event segments and atomically publishes its index.Testing
At
b39abf35, all five portable source checks passed. The SDK and MCP type checks passed. The plugin build used the source-matched universal native artifact. All 87 session reader, index and CLI navigation tests passed. Removing the database thread binding from the five existing discovery-retry cases reproduced the missing worker before the fix. The cases now pass, including rejection of duplicate, late or mismatched inputs.The SDK format check, 23 SDK tests for scan outcomes, resume and workflow identity, the end-to-end custom-validation retention case, all 46 Deep worker executor checks, and the complete bundled MCP smoke test passed. A broader SDK run was stopped after three fixtures failed inside an enclosing Git checkout. Both campaign cases and the workflow prompt-file case passed in private temporary directories outside that checkout.
On earlier revisions, contributors exercised the session reader with active, archived and compressed logs, multiple turns, cutoffs and overlapping invocations. Sixty current log-reader tests passed. Earlier integration tests exercised CLI and SDK result access, saved history, interrupted scans, directory reuse and package installation. A local native loopback test of a resumed thread retained the scan’s response and excluded the later manual turn. A second loopback test forced three failures in one thread with the pinned Codex 0.167.1. The private on-disk export retained the two receipted worker attempts and excluded the interleaved manual turn and both worker prompts. The reader, index, CLI navigation and MCP environment suites passed 90 tests. The complete MCP smoke test ran against a freshly built plugin, including its exact environment allowlist, and all 20 Deep worker runtime tests passed. A regression reproduced a stale exporter leaving directories in an empty replacement. With the fix, the replacement stayed empty and accepted a fresh scan without archival. Additional tests swapped the output or an artifact-directory link during publication and verified the replacement and link target received no files. Directory reuse discussion Earlier CI run
Risk and rollout
Retained events can contain prompts, source and tool output. Metadata collection is best effort. Older retry receipts without a native turn ID or an input digest cannot establish ownership. A missing, ambiguous, or out-of-window user item also leaves the attempt metadata-only. A failure before the native user item is persisted can have this outcome. Retry attribution discussion
Public disclosure review
Historical automated reviews link to the signed-in viewer’s Codex settings. Historical workflow logs were not reviewed in full.