Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
bump: minor
---

### Changed

- `/session-flow:workflow`'s explore stage no longer asks before investigating a file that is
missing from disk. It first runs `git status` and `git log` on that path, both read-only.
A staged or committed delete counts as intentional: the stage skips it and says so. A file
deleted only in the working tree is investigated. The stage asks only when neither command names
the path or a command fails.
13 changes: 11 additions & 2 deletions plugins/session-flow/skills/workflow/context/steps.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,17 @@ Structured local codebase exploration: read the relevant code, git history, file
dependencies. Understand current state before changing anything.

- Survey breadth-first (glob/grep), confirm the files the change touches, then read those in full
- When files referenced in git status or history don't exist on disk, ask before investigating.
They may be intentionally deleted
- When code, `git status` or history references a file that is not on disk, probe before any
investigation the task did not ask for. Run
`git --no-optional-locks status --porcelain -- <path>` and
`git log --oneline -1 --diff-filter=D -- <path>`, each its own read-only call. A status line
decides first; the deleting commit counts only when status prints nothing:
- **Intentional**: a staged removal (`D` in the first status column), or no status line and a
commit that deleted the path. Skip investigating it and say so, citing the status line or
commit
- **Unexplained**: deleted only in the working tree (`D` in the second status column).
Investigate it like any other file in scope
- **Not settled**: neither probe names the path, or a probe fails. Ask before investigating
Comment on lines +34 to +44

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No test covers the new rule. Closing issue #12594 sets two criteria:

  • "The step runs the git probe before any question."
  • "A question remains only for the case the probe cannot settle."

This bullet meets both. But no file under plugins/session-flow/evals/ covers the explore stage's missing-file gate. Searching for deleted, not on disk or diff-filter finds only the unrelated cs-env-worktree-not-pruned and re-first-split-hop cases.

That means a later edit could bring back ask-first wording, or drop one of the three branches, and nothing would fail. One example: an edit that makes a worktree-only delete ( D) count as intentional.

Suggested fix: add an eval case. A scaffold could build a repo with three files and reference all of them from code:

  • one staged-deleted (git rm);
  • one deleted only from the working tree (rm);
  • one deleted by an earlier commit.

The case would then assert that:

  • both probes run before any question;
  • the staged and committed deletes are skipped, with the status line or commit cited;
  • the worktree-only delete is investigated;
  • no question is asked.

claude-lane: claude-review

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pr-unblock / address-feedback: UNCERTAIN, left open

Evidence: plugins/session-flow/skills/workflow/context/steps.md:34, plugins/session-flow/evals/workflow-stage-5-settings-screen/case.yaml:8

The finding holds as far as the code shows. The new explore-stage rule (steps.md lines 34-44) sets three outcomes: intentional, unexplained and not settled. No case under plugins/session-flow/evals/ exercises it. No fix was made in this round, though. The suggested eval would need a git repo holding a staged delete, a worktree-only delete and a committed delete. Every eval case in this repository builds its fixture through context.scaffold_script, which points to a scaffold.sh file next to case.yaml, and the review-thread tool's check-paths refuses plugins/session-flow/evals/<case>/scaffold.sh because script files are outside this lane's scope. A case.yaml with no scaffold could not reach the gate. A person should add the case, with case.yaml, scaffold.sh and samples, or file it as a follow-up. The graders should check that both probes run before any question, that the staged and committed deletes are skipped with the evidence cited, that the worktree-only delete is investigated, and that no question is asked.

- **Effort:** reading and surveying code with no change made

## 2. Research
Expand Down
Loading