Repository navigation
Session follow-ups: run id and verified folders, aliases, declared deps, docs - #152
Conversation
Codex Review SummaryThis 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.
2 issues found across 12 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="website/content/docs/modes/agent.mdx">
<violation number="1" location="website/content/docs/modes/agent.mdx:40">
P2: The `/resume` sentence reads as if any past run can be resumed. Add that only runs which saved their SDK session can be resumed (agent and engineer runs from this version on), as the README does.</violation>
</file>
<file name="src/reverse_api/repl/app.py">
<violation number="1" location="src/reverse_api/repl/app.py:78">
P3: The aliases work when typed, but the `/` menu omits them because `palette_items()` reads only `COMMANDS`. Add both aliases to the menu so users can discover and complete them.</violation>
</file>
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
|
|
||
| The agent's steps, messages and reasoning stream into the conversation. Type a | ||
| follow-up when it finishes, answer its questions in the input bar, and press | ||
| `Esc` to stop it. `/resume` picks a past run back up where it stopped. |
There was a problem hiding this comment.
P2: The /resume sentence reads as if any past run can be resumed. Add that only runs which saved their SDK session can be resumed (agent and engineer runs from this version on), as the README does.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At website/content/docs/modes/agent.mdx, line 40:
<comment>The `/resume` sentence reads as if any past run can be resumed. Add that only runs which saved their SDK session can be resumed (agent and engineer runs from this version on), as the README does.</comment>
<file context>
@@ -23,12 +23,28 @@ English; providers such as Playwright MCP or Chrome DevTools MCP route browser a
+
+The agent's steps, messages and reasoning stream into the conversation. Type a
+follow-up when it finishes, answer its questions in the input bar, and press
+`Esc` to stop it. `/resume` picks a past run back up where it stopped.
+
## Running non-interactively
</file context>
| `Esc` to stop it. `/resume` picks a past run back up where it stopped. | |
| `Esc` to stop it. `/resume` picks a past run back up where it stopped, if it saved its session: agent and engineer runs from this version on can be resumed; collector runs cannot. |
| "/help": "keys and commands", | ||
| "/exit": "quit rae", | ||
| } | ||
| ALIASES = {"/quit": "/exit", "/commands": "/help"} |
There was a problem hiding this comment.
P3: The aliases work when typed, but the / menu omits them because palette_items() reads only COMMANDS. Add both aliases to the menu so users can discover and complete them.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At src/reverse_api/repl/app.py, line 78:
<comment>The aliases work when typed, but the `/` menu omits them because `palette_items()` reads only `COMMANDS`. Add both aliases to the menu so users can discover and complete them.</comment>
<file context>
@@ -75,6 +75,7 @@
"/help": "keys and commands",
"/exit": "quit rae",
}
+ALIASES = {"/quit": "/exit", "/commands": "/help"}
HISTORY_RUNS = 20
# Commands that open a picker are echoed once a choice shows something, not when the picker opens.
</file context>
| In a terminal, `agent`, `engineer` and `collector` open the session in their | ||
| mode and start the run, keeping options such as `--headless` and | ||
| `--output-dir` for the prompts you type next. `agent` and `engineer` print |
There was a problem hiding this comment.
Output folder promise is wrong
This says engineer keeps --output-dir for later prompts, but it only keeps that option for the first run. Unlike agent and collector, engineer supplies no runner to open_session; later tasks call run_engineer without output_dir. Both later run-ID prompts and free-text instructions therefore save generated scripts in the default folder instead of the chosen folder. This is a non-blocking documentation error that can leave users looking for results in the wrong place. Limit this promise to agent and collector, or preserve the option for engineer too.
Artifacts
Executable engineer session validation script
- The authored executable drives the real terminal/session dispatch with narrowly mocked generation and asserts initial versus subsequent output locations, making the reproduction rerunnable.
Engineer output before later prompts
- Executed the initial engineer task under a real PTY and captured arguments, file location, source ranges, command, and exit code 0, showing the chosen output folder is initially honored.
Engineer output after later prompts
- Executed the initial task followed by run-ID and free-text prompts under a real PTY and captured all arguments and fixture writes with exit code 0, showing both later tasks use the default folder.
Python interpreter restoration log
- Restored the missing Python 3.13.17 interpreter targeted by the supplied virtual environment's broken symlink, allowing the existing environment to execute the check.
Head verification and unchanged product code
- Captured the requested Git head, empty tracked diff, working-tree status, and executable-script checksum, confirming validation did not modify product code.
Ran code and verified through TREX
Prompt To Fix With AI
This is a comment left during a code review.
Path: website/content/docs/cli/commands.mdx
Line: 60-62
Comment:
**Output folder promise is wrong**
This says `engineer` keeps `--output-dir` for later prompts, but it only keeps that option for the first run. Unlike `agent` and `collector`, `engineer` supplies no `runner` to `open_session`; later tasks call `run_engineer` without `output_dir`. Both later run-ID prompts and free-text instructions therefore save generated scripts in the default folder instead of the chosen folder. This is a non-blocking documentation error that can leave users looking for results in the wrong place. Limit this promise to `agent` and `collector`, or preserve the option for `engineer` too.
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.…mmands by alias in the menu
There was a problem hiding this comment.
All reported issues were addressed across 4 files (changes from recent commits).
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
There was a problem hiding this comment.
All reported issues were addressed across 8 files (changes from recent commits).
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
…only shows when it fits
There was a problem hiding this comment.
1 issue found across 4 files (changes from recent commits).
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="src/reverse_api/cli.py">
<violation number="1" location="src/reverse_api/cli.py:1939">
P3: Scanning collector entries without `paths.har_dir` creates an empty `har/<run_id>` directory for each one because `get_har_dir()` creates directories. Resolve this fallback without creating the directory during a lookup.</violation>
</file>
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
|
|
||
| def _har_path(run_id: str, run: dict[str, Any]) -> Path: | ||
| """Where a run in history keeps its captured traffic.""" | ||
| return Path((run.get("paths") or {}).get("har_dir") or get_har_dir(run_id, None)) / "recording.har" |
There was a problem hiding this comment.
P3: Scanning collector entries without paths.har_dir creates an empty har/<run_id> directory for each one because get_har_dir() creates directories. Resolve this fallback without creating the directory during a lookup.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At src/reverse_api/cli.py, line 1939:
<comment>Scanning collector entries without `paths.har_dir` creates an empty `har/<run_id>` directory for each one because `get_har_dir()` creates directories. Resolve this fallback without creating the directory during a lookup.</comment>
<file context>
@@ -1927,10 +1927,16 @@ def engineer_from_prompt(text: str, model: str | None = None, output_dir: str |
+
+def _har_path(run_id: str, run: dict[str, Any]) -> Path:
+ """Where a run in history keeps its captured traffic."""
+ return Path((run.get("paths") or {}).get("har_dir") or get_har_dir(run_id, None)) / "recording.har"
</file context>
…lowups # Conflicts: # src/reverse_api/cli.py
Why
Follow-ups to #151:
/quitand/commandsstopped working.What
prompt-toolkitandmarkdown-it-pyas direct dependencies./quitruns/exitand/commandsruns/help. The/menu also matches them by alias.engineerpasses--output-diron to the prompts typed after its first run, likeagentandcollector../scriptscopy as absolute, clickable paths./resumecan pick up;Verification
pytest: 1194 passed, 8 skipped.ruff checkandmypyclean./commandsand/quit, the run id in the status row, the verified folders, and opening a folder by clicking it.pnpm buildinwebsite/: 22 pages.Out of scope
Porting
/settings, manual, collector and OpenCode runs into the session.