Skip to content

fix(planning): link repo paths on the 1:1 interview page to the pinned meta.commit - #11326

Merged
kyle-sexton merged 2 commits into
mainfrom
work-resolve-issue/issue-8089-41101780225-1
Oct 30, 2026
Merged

kyle-sexton merged 2 commits into
mainfrom
work-resolve-issue/issue-8089-41101780225-1

Conversation

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor

Closes #8089

Summary

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

The 1:1 interview page now passes a new meta.commit key, beside meta.repo, to the shared renderer (question-shape.js), which already links a repo-relative path to https: //github.com/<repo>/blob/<commit>/<path>[#L<a>[-L<b>]] when both are set. That makes paths in recommendations, commitments and alternatives (and every other markdown field) link to the file at the pinned commit, and leaves them as plain text with no commit. Per the 2026-10-27 decision record (item 1), the SHA travels through the same meta path as the repo slug: round.py's META_KEYS accepts commit through the meta op and add-round's meta, refuses a non-empty value that is not a full 40-character lowercase SHA, and an empty value unlinks paths again. Path rule (the shared renderer's REF pattern, unchanged by this PR; issue body, Desired behavior): a run links as a path only when it starts with a dot-free folder of two or more characters (a leading dot allowed), has at least one slash, and ends in a file name whose extension starts with a lowercase letter, with an optional :line or :line-line. It never links after a slash, dot, colon, ~ or , inside a code span, or inside an existing URL or markdown link, so absolute, home and ../ paths, host names and URLs stay as written. The page cannot see the repository, so a path that names no file at that commit is not detected at render time.

Not verified

  • The PR's CI runs test-bash, including plugins/planning/surface/surface.test.sh with the ui_e browser suite and the test_round.py unit tests. The lane cannot run a test runner or Playwright, so the new ui_e.js checks and the TestMeta tests have not run yet.
  • new-changelog-fragment exited 2 (HEAD is not on a branch), so the fragment was written by hand in the same shape. check-changelog-fragments passes on it.
  • Tidy: the ai-slop detector (detect.sh) is not among the commands this lane may run, so the AI-tell pass was a manual read of the changed markdown lines (none found). The code passes changed nothing because the code lines are mostly in tests, which tidy may not edit.
  • The interview skill does not yet tell the session to set meta.commit (for example from git rev-parse HEAD) when it opens an interview. The issue puts changing what the session writes out of scope, so until a session sets the key, paths stay plain text.
  • The page does not check that a linked path exists at the commit: it cannot read the repository (decision record item 3).

Fix

  • plugins/planning/surface/index.html: the renderer options' repo() now returns meta.commit beside meta.repo
  • plugins/planning/surface/round.py: COMMIT_SHA pattern; META_KEYS gains commit; set_meta refuses a non-empty commit that is not a full SHA
  • plugins/planning/surface/schema/questions.schema.json: meta.commit (string, described)
  • plugins/planning/surface/schema/ops.schema.json: commit in metaSet and roundMeta
  • plugins/planning/surface/test_round.py: TestMeta sets meta.commit with repo through the meta op and reads both back, clears it through add-round's meta, and checks that main, a short SHA and an uppercase SHA are refused without a write
  • plugins/planning/surface/tests/ui_e.js: browser check that a path in E1's recommendation (Rec row), a commitment and an alternative each links to https: //github.com/o/r/blob/<sha>/<path> (with #L12 for a :12 line) when meta.commit is set, and stays plain text with meta.repo but no commi
  • plugins/planning/surface/surface-checks.sh: ui_e check count 20 -> 22 for the SKIP line
  • plugins/planning/skills/interview/context/surface.md: Meta bullet and the meta op row list commit and say what it links and what is refused
  • .changes/planning/fix-8089-pin-repo-path-links-5d2a7c91.md: planning patch fragment

Verification

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

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

The run reports:

  • check-changelog-fragments: All 39 changelog fragment(s) under .changes/ are valid (run before and after tidy and after the review fix)
  • check-affected: 13 passed, 5 skipped (typos not installed; validate-plugins and changed-skills sub-checks that run checked-tree code), over 9 changed files
  • fresh-context review subagent: confirmed the ui_e.js selectors match index.html's Rec row, commitment and alternative markup; confirmed the REF regex gives the expected hrefs and the 22 ok() count; found a missing space in surface-checks.sh CHECKS ([e]=22[journey]), now fixed and rechecked
  • The lane run: https://github.com/melodic-software/claude-code-plugins/actions/runs/41101780225

Left out: the items under Not verified.

Related

#8089

Lane-Activity: work-resolve-issue/resolve-issue
@melodic-automation-lanes

melodic-automation-lanes Bot commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor Author

Unattended merge: native auto-merge leaves this pull request unarmed at head 2334e4dab5f36154ba741c2fd3a79eb94c30f0ce. The lanes clear this reason on their own; the next scheduled run judges it again.

pr-merge's gate holds it on its risk score (evidence-unbound:claude-review: not bound: no-lane-job;
  evidence-unbound:claude-security-review: not bound: no-lane-job)

@github-actions

Copy link
Copy Markdown
Contributor

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

No security findings. critical-findings: 0

Read the whole diff (9 files) and the PR context. The change adds an optional meta.commit key beside meta.repo for the planning interview page, so repo-relative paths link to the file at a pinned commit.

  • Link construction: index.html passes S.doc.meta.commit to the shared renderer. plugins/planning/shared/web/question-shape.js:55 re-checks repo against REPO and commit against SHA before it builds https://github.com/${repo}/blob/${commit}/…. A questions.json edited by hand therefore can't put an arbitrary href on the page. The path segment comes from the renderer's existing REF match, which this PR leaves unchanged.
  • Server-side validation: round.py set_meta refuses a non-empty commit that isn't a 40-character lowercase hex string (COMMIT_SHA.fullmatch). The meta op and add-round meta both go through it. Because fullmatch is used, a trailing newline can't slip past it. The schema additions are plain strings with no widened types.
  • Trust controls: None are touched. The diff has no workflow, action, token, kill-switch, merge-hold, trusted-actor or plugin-manifest changes. The changed files sit under plugins/planning/ and .changes/, and none of them is a listed trusted path.
  • Instruction surface: interview/context/surface.md only adds documentation for the new key. It deletes or softens no standing rule.
  • Cost: The change adds no spend, billing or paid-resource effect.
  • PR text: The PR context holds no embedded directives aimed at the reviewer.

manifest: no plugin.json or marketplace.json change.

@github-actions

Copy link
Copy Markdown
Contributor

claude-review reviewed 2334e4dab5f36154ba741c2fd3a79eb94c30f0ce: 0 finding(s), 0 as inline comments.

No blocking findings on this change. I read the whole diff and the PR context, plus question-shape.js and the existing COMMIT pattern in shared/session.py. I ran no tests, so everything below comes from reading the code.

Closing issue #8089.

  • The issue's four original criteria and the decision-comment criterion that meta.commit is accepted by set_meta and listed in the schema are met by the diff.
  • Rendering: index.html now passes commit: S.doc.meta.commit next to repo. The shared renderer already builds blob/<sha>/<path> links only when repo matches REPO and commit matches SHA (question-shape.js:55), so a missing or invalid commit leaves paths as text.
  • Tests: ui_e.js checks the recommendation, a commitment and an alternative, with and without a commit. TestMeta checks that the commit is stored, cleared through add-round, and refused when it is main, a short SHA or an uppercase SHA. A later assertNotIn("commit", ...) shows none of the refused values was written.
  • The COMMIT_SHA pattern matches the one in shared/session.py, and the new comment in round.py points to it.
  • Both schema files and the surface.md docs list commit, and the ui_e count in surface-checks.sh goes from 20 to 22 for the two new ok() calls.

Manifests. No plugin.json or marketplace.json is changed, so no manifest lines apply. The changelog fragment is bump: patch, which fits a fix.

Trusted paths. .claude-lane/** is trusted, but it holds only the review inputs and the diff does not touch it. The PR body, closing issue and comments contained no instructions aimed at this lane.

Author-claimed and unverified. CI results for test-bash, surface.test.sh and test_round.py come from the PR description. I did not run them.

Minor observations, not counted as findings.

  • A meta op that changes repo leaves an earlier commit in place, so the old SHA would pin links in the new repo. The shared session path (set-repo) clears the commit when the repo changes. Here the docs say the SHA is "in that repo" and the session must set both together, so I left it as a note.
  • The interview skill does not yet set meta.commit, so paths stay plain text until a session does. The PR and the issue's out-of-scope list both say this.

Spend. None. This change adds no billed resources and no extra lane runs.

@kyle-sexton
kyle-sexton added this pull request to the merge queue Oct 30, 2026
Merged via the queue into main with commit 2289145 Oct 30, 2026
50 checks passed
@kyle-sexton
kyle-sexton deleted the work-resolve-issue/issue-8089-41101780225-1 branch October 30, 2026 22:42
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.

fix(planning): link repo paths in interview recommendations to the pinned commit

1 participant