Skip to content

feat(education): persist a closed mission state in teach - #10161

Merged
melodic-automation-lanes[bot] merged 3 commits into
mainfrom
work-resolve-issue/issue-6408-40261905392-1
Oct 26, 2026
Merged

melodic-automation-lanes[bot] merged 3 commits into
mainfrom
work-resolve-issue/issue-6408-40261905392-1

Conversation

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor

Closes #6408

Summary

Opened by the work-resolve-issue lane. The run's own summary:

Choosing close at the teach resume step now writes a Status: closed line under the MISSION.md title (owner decision D16, option a). list-workspaces.sh marks such a workspace (closed), status reports it as closed, explain/exercise and discovery no longer treat it as active, and resume on a closed mission offers reopen, revise or leave closed instead of re-offering close-or-revise. Three new eval cases and new list-workspaces.sh test assertions cover the behavior.

Not verified

  • list-workspaces.test.sh was not executed: this lane runs only the named wrappers and check-affected runs without --tests; the new assertions were desk-checked by me and the review subagent. CI's test lane runs it.
  • The eval suite (claude plugin eval) was not run: it needs paid model runs. So the three new cases and the existing resume-success-criteria-met and control-resume-criteria-not-met are unmeasured; the llm graders' samples also need a judge calibration run.
  • The plugins/evals validate script (Python) was not run on the new cases: no interpreter is allowed in this lane.
  • New scaffold.sh files are written mode 0644; sibling scaffolds are 100755. check-affected's snapshot and apply-patch set the exec bit on new .sh files, so this should resolve on apply; not confirmed on the pushed commit.
  • Review note not acted on: line-says-closed and offers-reopen may also pass in the no-plugin arm, since a model that reads MISSION.md sees the closed line; the llm graders and closed-probe carry the discrimination. Worth checking after the first paid run.

Fix

  • plugins/education/skills/teach/context/mission.md: new 'Closing and reopening' section defining the Status: closed line (where it goes, reopen = delete it, only the exact value closed closes) and a row in the 'Where the file is used' table; the template itself stays without a status line
  • plugins/education/skills/teach/SKILL.md: discovery treats a (closed) path as closed and never offers it as active; resume-without-topic lists closed workspaces after active ones; status shows closed in place of frontier and due flag, with a grep probe for the hand-glob fallback; explain/exercise
  • plugins/education/skills/teach/scripts/list-workspaces.sh: appends (closed) to a workspace whose MISSION.md has a line matching ^Status:\[\[:space:\]\]*closed\[\[:space:\]\]*$ (CRLF tolerant), before the legacy-slug label; help text updated
  • plugins/education/skills/teach/scripts/list-workspaces.test.sh: new Case 9b (closed, CRLF closed, active, Status: closed later, no MISSION.md) and a closed legacy workspace assertion in Case 11
  • plugins/education/evals/resume-close-persists-status/: new case (case.yaml, scaffold.sh, samples for read-mission, writes-status-closed, closes-in-mission-file) checking that choosing close persists Status: closed in MISSION.md
  • plugins/education/evals/status-closed-mission/: new case (case.yaml, scaffold.sh, samples for closed-probe, line-says-closed, not-reported-active) checking status reports a closed workspace as closed, not active
  • plugins/education/evals/resume-closed-mission/: new case (case.yaml, scaffold.sh, samples for read-mission, offers-reopen, no-close-offer-again) checking resume on a closed mission offers reopen or revise and does not re-offer close-or-revise
  • .changes/education/feat-6408-teach-closed-mission-a3c91f07.md: minor-bump changelog fragment (written by hand: new-changelog-fragment refused because HEAD is detached in this checkout)

Verification

The runner ran each check from the base copy against ce8bac5:

  • scripts/check-changelog-fragments.sh --check: passed

The run reports:

  • /home/runner/work/claude-code-plugins/claude-code-plugins/.lane/checks/bin/check-changelog-fragments: All 5 changelog fragment(s) under .changes/ are valid
  • /home/runner/work/claude-code-plugins/claude-code-plugins/.lane/checks/bin/check-affected: 10 passed, 6 skipped (validate-plugins sub-steps, ruff, typos, changed-skills skipped as running checked-tree code or tool absent), 0 failed over 20 changed files
  • cant-fail-scan --file plugins/education/skills/teach/scripts/list-workspaces.test.sh --check: PASS, no gating findings
  • fresh-context review subagent over the whole diff: found the Status: closed line inside the MISSION.md template (would close every new mission), probe mismatch between script (-i) and SKILL.md fallback, ambiguous status probe wording, no 'leave closed' exit on resume, and a weak co-occurrence grad
  • read https: //code.claude.com/docs/en/plugin-evals: context.scaffold_script is a Bash script in the case directory that runs in the empty workspace before Claude starts, only under --scaffold
  • The lane run: https://github.com/melodic-software/claude-code-plugins/actions/runs/40261905392

Left out: the items under Not verified.

Related

#6408

Lane-Activity: work-resolve-issue/resolve-issue
@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 66c9f6fc6337408552aac958e66a2882fa737fb0: 0 finding(s), 0 as inline comments.

Security review of PR #10161 found no security issues.

Scope. 20 files, all in the education plugin's teach skill (SKILL.md, context/mission.md, list-workspaces.sh and its test), three new eval cases with their scaffold scripts, and a changelog fragment. No changed file matches a trusted path. The change touches no trust control, workflow, .github/actions/ file, plugin manifest, hook or userConfig key.

What I checked

  • list-workspaces.sh: the new closed_mark() helper runs grep -qE with a fixed pattern on "$1MISSION.md". The path comes from a glob over the configured roots, always quoted and ending in /. Nothing in MISSION.md is evaluated, so there is no command or path injection. A symlinked MISSION.md is only read.
  • Scaffold scripts: they use fixed relative paths and set -euo pipefail, take no external input, and write only into the empty eval workspace. They run only under --scaffold.
  • Instruction surface (SKILL.md, context/mission.md): the edits add behavior (a closed state, reopen, revise, leave closed) and remove no guardrail. Nothing in the diff deletes, narrows or softens a standing instruction. I did not read docs/conventions/instruction-exception-register/README.md, so I did not check against its protected-class list.
  • The Status: closed line only changes how listing, status and resume present a workspace. It gates no permission, token, merge or kill-switch behavior.
  • The eval cases only allow read-only tools (Read, Glob, Grep, Skill). The sample JSON files are inert data.
  • The PR context contains no embedded instructions aimed at the lane.

manifest: not hit (no plugin.json or marketplace.json change).

critical-findings: 0

Spend: the three new eval cases use prepaid model runs when someone runs them. That is not a hold.

@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

claude-review reviewed 66c9f6fc6337408552aac958e66a2882fa737fb0: 0 finding(s), 0 as inline comments.

No blocking or advisory findings. I read the whole diff (20 files) and the PR context; I did not run any tests or evals.

Closing issue #6408 (decision D16, option a: a Status: closed line in MISSION.md):

  • A persisted closed state, written when the learner chooses close. Met. context/mission.md "Closing and reopening" defines the line, and SKILL.md resume step 2 writes it on close. resume-close-persists-status covers this.
  • list-workspaces.sh and discovery stop offering a closed workspace as active. Met. closed_mark in list-workspaces.sh appends (closed). The pattern ^Status:[[:space:]]*closed[[:space:]]*$ tolerates CRLF and rejects Status: closed later. SKILL.md discovery and the explain/exercise rules treat a (closed) path as not active. list-workspaces.test.sh Case 9b and the legacy-slug case in Case 11 cover the script.
  • status shows it as closed. Met. The status line says closed in place of the frontier and due flag, with a grep fallback that uses the same pattern as the script. status-closed-mission covers this.
  • resume on a closed workspace does not re-offer close-or-revise and offers to reopen or revise. Met. Step 2 offers reopen, revise or leave closed, and skips steps 3 and 4. resume-closed-mission covers this.
  • An eval case for each behavior. Met by three new cases.

What I checked:

  • The new scaffold.sh files match the existing resume-success-criteria-met scaffold. The head -n 1 / tail -n +2 splice puts the status line under the title of the existing workspaces/sql-joins/MISSION.md.
  • The closed_mark command substitution cannot fail under set -e, because the if keeps its exit status at 0.
  • (closed) comes before (legacy worktree slug) in the script, and the new test asserts that order.
  • The MISSION.md template has no status line, so new missions are not closed by default.
  • The changelog fragment is a minor bump. That fits a new user-visible capability.
  • No plugin.json or marketplace.json change is in the diff, so there are no manifest items.
  • No trusted-path file is changed.

Not verified (author-claimed, and I did not run them): the test script, the eval suite, and the evals validator. The PR description says none of these ran.

Minor, not counted as findings:

  • closed_mark matches a Status: closed line anywhere in MISSION.md, while the docs say "under the title". Only a line that is exactly Status: closed can trip it, so this is unlikely to matter.
  • The new eval prompts and graders say "Result and Checks". The sql-joins fixture MISSION.md uses the older "Success Looks Like" layout. mission.md says legacy layouts are read by meaning, so this is harmless.

Spend: the three new eval cases and their llm graders use prepaid or subscription model runs only. That is not a hold.

Comment thread plugins/education/skills/teach/SKILL.md Resolved
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

pr-unblock / address-feedback finished round 1 of max 4 on 036af4c.

@melodic-automation-lanes melodic-automation-lanes Bot added the needs-human Human-in-the-loop required; autonomous sessions must not resolve items carrying this. label Oct 26, 2026
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The pr-unblock lane stopped on this pull request and needs a person: a disputed review finding is one only a person decides (a security-review finding, a thread a person directed, or one an adjudicator found stands and the next round left open again).

  • Reason: feedback-disputed
  • Resume key: 036af4c236d60d44eb05a568cf53ce24bf48717c (the head the lane stopped on)

To resume, deal with the reason above, remove the needs-human label (and do-not-merge, if set), then dispatch the pr-unblock workflow with pr-number=10161 and activity=address-feedback:

gh workflow run pr-unblock.yml -R melodic-software/claude-code-plugins -f pr-number=10161 -f activity=address-feedback

@kyle-sexton kyle-sexton removed the needs-human Human-in-the-loop required; autonomous sessions must not resolve items carrying this. label Oct 26, 2026
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The unattended merge path armed native auto-merge at head 66c9f6fc6337408552aac958e66a2882fa737fb0.

@melodic-automation-lanes
melodic-automation-lanes Bot added this pull request to the merge queue Oct 26, 2026
@melodic-automation-lanes
melodic-automation-lanes Bot removed this pull request from the merge queue due to a manual request Oct 26, 2026
@melodic-automation-lanes
melodic-automation-lanes Bot added this pull request to the merge queue Oct 26, 2026
@melodic-automation-lanes
melodic-automation-lanes Bot removed this pull request from the merge queue due to a manual request Oct 26, 2026
@melodic-automation-lanes
melodic-automation-lanes Bot added this pull request to the merge queue Oct 26, 2026
Merged via the queue into main with commit b241eed Oct 26, 2026
76 of 78 checks passed
@melodic-automation-lanes
melodic-automation-lanes Bot deleted the work-resolve-issue/issue-6408-40261905392-1 branch October 26, 2026 16:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(education): persist a closed mission state so teach stops re-offering close-or-revise

1 participant