Skip to content

/run-feedback never recommends the merge when the first review has no finding #688

Done

Description

@polewskm

Note

Repositories:

Attach or clone each before working on this issue.

What

/run-feedback's Recommend the Merge section says: "A pass that finds no item before the run has had a round recommends nothing, on purpose: nothing on the pull request has been reviewed or answered yet, so the run keeps checking for comments and reviews until the wait limit passes."

That reason doesn't hold once NCode Review has already reviewed the head. /ship-plan opens the pull request, NCode Review reviews it on open, and when that review has no finding at all, the first pass finds no item, the run has had no round, and so the run never recommends the merge: it checks every five minutes for 24 hours and ends without a recommendation, although the pull request is as clean as it gets. A pull request whose first review has two nits gets a recommendation in its first pass (the pass found items); one whose first review has none never does.

Seen in NCodeGroup/Collections.Providers#41 (Update from project-template v0.154.0): NCode Review's summary says Verdict: ✅ Approve — No findings, the NCode Review Approver approved the head b7e9a73, every check passed and the default branch's newest commit is green, but the first pass has no item and no round, so /run-feedback 41 may post no recommendation.

Change

In run-feedback.prompt.md (and its Claude command and skill copies), also recommend the merge after a pass that finds no item when NCode Review's review of the pull request's head is in, as the Code review check run on the head shows, and found nothing left to act on; keep recommending nothing while no review of the head has arrived.

Not in this issue

  • The max-review-rounds cap and the merge-only push rules.

Activity

  1. polewskm commented on Nov 30, 2026

    @polewskm
    CollaboratorAuthor

    Also seen in NCodeGroup/Extensions.DataProtection#39 (Update from project-template v0.154.0): NCode Review's summary says Verdict: ✅ Approve — No findings, the NCode Review Approver approved the head 91599fc, and the first pass has no item and no round, so /run-feedback 39 posts no recommendation. NCodeGroup/Extensions.DataProtection's next /run-feedback can check the fix too.

  2. polewskm commented on Nov 30, 2026

    @polewskm
    CollaboratorAuthor

    Also seen in NCodeGroup/identity-platform#52 (Update to project-template v0.154.0): NCode Review's summary says Verdict: ✅ Approve — No findings, the NCode Review Approver approved the head e78feb3, every check passed and the default branch's newest commit is green, but the first /run-feedback 52 pass has no item and no round, so it posts no recommendation. NCodeGroup/identity-platform's next /run-feedback can check the fix too.

  3. polewskm commented on Nov 30, 2026

    @polewskm
    CollaboratorAuthor

    Also seen in NCodeGroup/code-review#264 (Update from project-template v0.154.0): NCode Review's summary says Verdict: ✅ Approve — No findings in this repository's own files (its two findings belong upstream, in .template/Update-Project.ps1, so they get no thread), the NCode Review Approver approved the head 5534c34, and the first /run-feedback 264 pass has no item and no round, so it posts no recommendation. NCodeGroup/code-review's next /run-feedback can check the fix too.

  4. polewskm commented on Dec 1, 2026

    @polewskm
    CollaboratorAuthor

    Also seen in NCodeGroup/PropertyBag#91 (Update from project-template v0.154.0): NCode Review's first review said Verdict: ✅ Approve — No findings and the NCode Review Approver approved head d483368, so the first pass found no item and, with no round yet, recommended nothing. The run only reached a recommendation because the pull request was later retargeted to v0.154.1, whose push and /review brought two nit findings.

  5. polewskm commented on Dec 1, 2026

    @polewskm
    CollaboratorAuthor

    Plan snapshot. The working copy is PLAN.md in the plan's checkout; this comment is not updated as steps run.

    Plan: Fix the baseline note's form and the clean-first-review recommendation (9 steps)

    Plan: Fix the baseline note's form and the clean-first-review recommendation

    Issue: #689 #688
    Release: v0.154.2

    Goal

    #689: an update that adds .github/workflows/codeql.yml prints the baseline command twice in two forms, because Get-CodeQLWorkflowNote still prints tools/Set-RepositoryBaseline.ps1 -Repo <name> -Owner <owner> while Get-BaselineNote prints ADR-0068's -Repo <owner>/<name>. After this plan every baseline command an update or an adoption prints uses -Repo <owner>/<name>. #688: /run-feedback never recommends the merge when NCode Review's first review has no finding, because a pass with no item before any round recommends nothing. After this plan such a pass recommends the merge once NCode Review's review of the pull request's head commit is in, as its Code review check run shows, and still recommends nothing while no review of the head has arrived. /run-issues has the same gap and gets the same fix.

    Context for the executor

    • Build: none (AGENTS.md names no build command).
    • Test:
      • pwsh -NoProfile -File tests/Test-UpdateNotes.ps1 (about 50 seconds, no Node.js needed).
      • pwsh -NoProfile -File tests/Test-Template.ps1 -Only none (one to three minutes, depending on the PC's load). It needs Node.js 26 on PATH, and Node.js is not on PATH in this PC's shells. So every Done-when command that runs it first runs $env:Path = [Environment]::GetEnvironmentVariable('Path','Machine') + ';' + [Environment]::GetEnvironmentVariable('Path','User'); . nvs.ps1 use 26 | Out-Null in the same command. Copier is already installed. -Only none skips the project renders and runs every workflow check.
      • pwsh -NoProfile -File tests/Test-Adoption.ps1 -UnitOnly (about 10 seconds).
    • Conventions:
      • Scripts are PowerShell 7. Keep each edited line's indentation as it is.
      • The workflow's prompt sources are workflow/templates/*.md. _run-feedback-body.md is the body of /run-feedback in every tool. run-issues.md (Claude Code) and run-issues-copilot.md (Copilot) are the two sources of /run-issues.
      • Each numbered item or paragraph in these Markdown sources is one long line. "Replace X with Y" means: find X, which appears exactly once in the file, and put Y in its place on the same line. Never start a new line unless the step says so.
      • Copy every quoted text exactly as given, including backticks, quotes, {owner}/{repo} and spacing. The files use LF line endings.
      • Write prose with no AI agent attribution.
    • Gotchas:

    Decisions

    • Kind: bugfix for both. Update-Project.ps1's CodeQL note still prints the baseline as -Repo <name> -Owner <owner>, beside ADR-0068's -Repo <owner>/<name> #689 is a Task with no label and /run-feedback never recommends the merge when the first review has no finding #688 has no type and no label; both describe output or behavior that is wrong. Release v0.154.2 is a patch raise over v0.154.1, the newest tag on origin, because the fix ships in template/, workflow/ and Adopt-Project.ps1.
    • Root cause Update-Project.ps1's CodeQL note still prints the baseline as -Repo <name> -Owner <owner>, beside ADR-0068's -Repo <owner>/<name> #689: Get-CodeQLWorkflowNote predates ADR-0068 and splits $slug into $owner and $name for its last line. v0.154.0 added Get-BaselineNote with -Repo <owner>/<name> but left this note alone, and tests/Test-UpdateNotes.ps1 pins the old form ('tools/Set-RepositoryBaseline.ps1 -Repo brand -Owner NCodeGroup'). Evidence: template/.template/Update-Project.ps1 lines 1029-1039 and 1045-1050.
    • Update-Project.ps1's CodeQL note still prints the baseline as -Repo <name> -Owner <owner>, beside ADR-0068's -Repo <owner>/<name> #689 fix: the note prints -Repo $slug, the issue's first option. Dropping the line instead would break Adopt-Project.ps1, whose copy must stay equal and which prints no baseline note after it, and an update whose origin isn't on GitHub, which prints no baseline note at all.
    • Adopt-Project.ps1's own "Protect the default branch" command also moves to -Repo $originRepository. Otherwise the adoption would print -Repo plain -Owner example and then the CodeQL note's -Repo example/plain, the same two-forms problem Update-Project.ps1's CodeQL note still prints the baseline as -Repo <name> -Owner <owner>, beside ADR-0068's -Repo <owner>/<name> #689 reports. docs/adopt.md 2.1 already says -Repo <owner>/<name>.
    • Root cause /run-feedback never recommends the merge when the first review has no finding #688: _run-feedback-body.md's Recommend the Merge recommends only "once the run has had a round or that pass found items", and says a pass with no item before a round recommends nothing. Nothing reads whether NCode Review already reviewed the head: Wait tracks only the review of <pushed>, a push the run made. A clean first review gives no item and no round, so the condition never holds (Collections.Providers#41, Extensions.DataProtection#39, identity-platform#52, code-review#264).
    • /run-feedback never recommends the merge when the first review has no finding #688 fix: a pass with no item before any round reads the Code review check run on the pull request's head commit and recommends when a completed NCode Review run there has the conclusion neutral and a title that doesn't start with Review. Evidence, from NCodeGroup/code-review's src/publish.ts and src/checks.ts: a posted review completes the check run neutral with a title that counts its findings (No findings, No new findings, … or <n> blocker, <n> should-fix, <n> nit); a run that posted no review completes it with Review skipped, Review budget used up, Review paused (all neutral), Review failed, Review stopped, Review cancelled or Reviewed <sha> instead. The query returns 1 on Collections.Providers#41's head (No findings) and counts code-review#264's head (0 blocker, 0 should-fix, 2 nit, whose findings have no thread here) as reviewed, as the issue asks.
    • The run-feedback recommendation names <head commit>, and a no-round recommendation is skipped when an Autopilot: comment already recommends that commit, so a restarted /run-feedback doesn't recommend the same head twice ("each head of the branch gets at most one recommendation").
    • /run-issues (Review the Pull Request item 9) has the same gap: a first review with no finding is neither a round nor a check that found findings. It gets the same check-run condition. /run-issues-all-in already recommends "whether or not the entry has had a round" and needs nothing.
    • No decision record changes: ADR-0019 decision 4 already says the commands recommend once NCode Review's findings are answered and its review is in.
    • Both issues' author is a MEMBER, so the changelog thanks no one.

    Out of scope

    • tools/Set-RepositoryBaseline.ps1, New-Project.ps1 and template/.template/Test-MergeGate.ps1, which still pass or print -Owner; see Follow-ups.
    • The max-review-rounds cap, the merge-only push rules, Wait's hour-long wait for <pushed>, _land-auto.md and _stop-the-line.md.
    • _run-issues-all-in-body.md, address-feedback, ship-plan and every decision record.
    • Rewording any sentence a step doesn't quote.
    • Running tools/Set-RepositoryBaseline.ps1 or any end-to-end test under tests/e2e/.

    Steps

    [ ] 1. Add a failing check that the CodeQL note prints -Repo /

    • Issue: Update-Project.ps1's CodeQL note still prints the baseline as -Repo <name> -Owner <owner>, beside ADR-0068's -Repo <owner>/<name> #689
    • Files: tests/Test-UpdateNotes.ps1 (edit)
    • Change:
      1. In the comment-based help, replace the four lines of the codeql paragraph (from codeql Get-CodeQLWorkflowNote names codeql.yml, … through modifies it or adds another file.) with these five lines, indented as the old ones are: 6 spaces before codeql, 16 spaces before each other line:
              codeql    Get-CodeQLWorkflowNote names codeql.yml, the languages, the gh api command that turns the default setup
                        off for the origin's repository, or <owner>/<name>, before the merge, the re-run, the baseline command
                        tools/Set-RepositoryBaseline.ps1 -Repo with that same <owner>/<name> and no -Owner, and 'Enabled with
                        advanced setup allowed' when the update adds codeql.yml, and says nothing when it modifies it or adds
                        another file.
        
      2. In the $codeqlNote block, replace 'tools/Set-RepositoryBaseline.ps1 -Repo brand -Owner NCodeGroup' with 'tools/Set-RepositoryBaseline.ps1 -Repo NCodeGroup/brand from the template''s clone'.
      3. Replace 'tools/Set-RepositoryBaseline.ps1 -Repo <name> -Owner <owner>' with 'tools/Set-RepositoryBaseline.ps1 -Repo <owner>/<name> from the template''s clone'.
      4. In the line Check "codeql: $name" (…), replace -and -not $note.Contains('once this update merges, you run')) with -and -not $note.Contains('once this update merges, you run') -and -not $note.Contains(' -Owner ')).
    • Done when: $o = pwsh -NoProfile -File tests/Test-UpdateNotes.ps1 2>&1; $code = $LASTEXITCODE; $fails = @($o | Where-Object { "$_" -match '^FAIL ' }); if ($code -and $fails.Count -eq 2 -and @($fails | Where-Object { "$_" -match '^FAIL codeql: added ' }).Count -eq 1 -and @($fails | Where-Object { "$_" -match '^FAIL codeql: added, origin not on GitHub ' }).Count -eq 1) { exit 0 } else { exit 1 }

    [ ] 2. Print the CodeQL note's baseline command as -Repo /

    • Issue: Update-Project.ps1's CodeQL note still prints the baseline as -Repo <name> -Owner <owner>, beside ADR-0068's -Repo <owner>/<name> #689
    • Files: template/.template/Update-Project.ps1 (edit), Adopt-Project.ps1 (edit)
    • Change: in function Get-CodeQLWorkflowNote of each file, make the same two edits, so the two copies stay character for character equal:
      1. Delete the line $owner, $name = $slug -split '/', 2.
      2. In the last line of the function, replace -Repo $name -Owner $owner from the template's clone with -Repo $slug from the template's clone.
    • Pattern: Get-BaselineNote right below it in Update-Project.ps1, which prints -Repo $Repository.
    • Done when: $o = pwsh -NoProfile -File tests/Test-UpdateNotes.ps1 2>&1; $code = $LASTEXITCODE; if ($code -or -not ($o -match '^PASS codeql: added$') -or -not ($o -match '^PASS codeql: added, origin not on GitHub$') -or -not ($o -match '^PASS copies: ') -or (Select-String -LiteralPath template/.template/Update-Project.ps1, Adopt-Project.ps1 -SimpleMatch -Pattern '-Repo $name -Owner $owner' -Quiet)) { exit 1 } else { exit 0 }

    [ ] 3. Print the adoption's baseline command as -Repo /

    • Issue: Update-Project.ps1's CodeQL note still prints the baseline as -Repo <name> -Owner <owner>, beside ADR-0068's -Repo <owner>/<name> #689
    • Files: Adopt-Project.ps1 (edit), tests/Test-Adoption.ps1 (edit), tests/Test-AdoptEdgeCases.ps1 (edit)
    • Change:
      • Adopt-Project.ps1, in the if ($originRepository) { block that prints Protect the default branch, …:
        1. Replace $owner, $repo = $originRepository -split '/', 2 with $repo = ($originRepository -split '/', 2)[1].
        2. Replace 'tools/Set-RepositoryBaseline.ps1') -Repo $repo -Owner $owner" with 'tools/Set-RepositoryBaseline.ps1') -Repo $originRepository".
      • tests/Test-Adoption.ps1:
        1. Replace $out.Contains('-Repo plain -Owner example') with $out.Contains('-Repo example/plain') -and -not $out.Contains('-Repo plain -Owner').
        2. Replace $out.Contains('-Repo Demo -Owner NCodeGroup') with $out.Contains('-Repo NCodeGroup/Demo') -and -not $out.Contains('-Repo Demo -Owner').
      • tests/Test-AdoptEdgeCases.ps1: replace $ciOut.Contains('-Repo ci-existing -Owner example') with $ciOut.Contains('-Repo example/ci-existing') -and -not $ciOut.Contains('-Repo ci-existing -Owner').
    • Done when: $bad = @(foreach ($f in 'Adopt-Project.ps1', 'tests/Test-Adoption.ps1', 'tests/Test-AdoptEdgeCases.ps1') { $errs = $null; [void][Management.Automation.Language.Parser]::ParseFile((Join-Path (Get-Location) $f), [ref]$null, [ref]$errs); if ($errs) { "$f does not parse" } }); $a = Get-Content -Raw -LiteralPath Adopt-Project.ps1; $t = Get-Content -Raw -LiteralPath tests/Test-Adoption.ps1; $e = Get-Content -Raw -LiteralPath tests/Test-AdoptEdgeCases.ps1; if (-not $a.Contains('tools/Set-RepositoryBaseline.ps1'') -Repo $originRepository"') -or -not $a.Contains('$repo = ($originRepository -split ''/'', 2)[1]') -or $a.Contains('-Owner $owner') -or -not $t.Contains('$out.Contains(''-Repo example/plain'')') -or -not $t.Contains('$out.Contains(''-Repo NCodeGroup/Demo'')') -or $t.Contains('-Repo plain -Owner example') -or $t.Contains('-Repo Demo -Owner NCodeGroup') -or -not $e.Contains('$ciOut.Contains(''-Repo example/ci-existing'')') -or $e.Contains('-Repo ci-existing -Owner example')) { $bad += 'text' }; pwsh -NoProfile -File tests/Test-Adoption.ps1 -UnitOnly | Out-Null; if ($LASTEXITCODE) { $bad += 'unit' }; if ($bad) { $bad; exit 1 } else { exit 0 }

    [ ] 4. Add a failing check that a clean first review gets the merge recommended

    • Issue: /run-feedback never recommends the merge when the first review has no finding #688
    • Files: tests/Test-Template.ps1 (edit), docs/tests.md (edit)
    • Change:
      • tests/Test-Template.ps1: right after the line that starts Check 'workflow: run-feedback reaches Claude Code from run-feedback.md, and before the comment line # run-issues-all-in follows run-issues' installed file …, add these six lines:
        # Before any round, a pass or check with nothing to answer recommends the merge once NCode Review's review of the pull request's head commit is in, as its Code review check run shows, and nothing while none has arrived (#688).
        $headReviewText = '.conclusion == "neutral" and ((.output.title // "Review") | startswith("Review") | not)'
        $m = @(Get-MissingText ($feedbackFiles + $copilotFeedbackFiles) ('A pass that finds no item before the run has had a round reads that review', 'commits/<head commit>/check-runs?check_name=Code%20review', $headReviewText, 'already recommends the merge at `<head commit>`', 'ready to merge at `<head commit>` as far as this run can tell'))
        $m += @(Get-MissingText ($runFiles + $copilotRunFiles) ('or that check found nothing awaiting an answer and NCode Review''s review of `<head commit>`', 'commits/<head commit>/check-runs?check_name=Code%20review', $headReviewText, 'a check that finds nothing awaiting an answer before the entry''s first round recommends nothing'))
        $m += @(foreach ($p in $feedbackFiles + $copilotFeedbackFiles) { if ([IO.File]::ReadAllText((Join-Path $repoRoot $p)).Contains('before the run has had a round recommends nothing, on purpose')) { "${p}: still recommends nothing after a first pass with no item" } })
        Check 'workflow: run-feedback and run-issues recommend the merge after a first pass or check with nothing to answer once NCode Review''s review of the head commit is in, and recommend nothing while none has arrived (#688)' (-not $m) ($m -join '; ')
        
      • docs/tests.md: right before the line that starts - `_land-auto.md` and `_stop-the-line.md` are in each generated copy, add these two lines:
        - Each generated copy of `run-feedback` and `run-issues` recommends the merge after a pass or check that finds nothing to answer before the first round once NCode Review's `Code review` check run on the pull request's head commit shows a posted review, and recommends nothing while none has arrived
          - **For:** Always
        
    • Done when: $env:Path = [Environment]::GetEnvironmentVariable('Path','Machine') + ';' + [Environment]::GetEnvironmentVariable('Path','User'); . nvs.ps1 use 26 | Out-Null; $o = pwsh -NoProfile -File tests/Test-Template.ps1 -Only none 2>&1; $code = $LASTEXITCODE; $fails = @($o | Where-Object { "$_" -match '^FAIL ' }); if ($code -and $fails.Count -eq 1 -and "$($fails[0])" -match '^FAIL workflow: run-feedback and run-issues recommend the merge after a first pass' -and (Select-String -LiteralPath docs/tests.md -SimpleMatch -Pattern 'shows a posted review, and recommends nothing while none has arrived' -Quiet)) { exit 0 } else { exit 1 }

    [ ] 5. Recommend the merge after a clean first review in run-feedback

    • Issue: /run-feedback never recommends the merge when the first review has no finding #688
    • Files: workflow/templates/_run-feedback-body.md (edit)
    • Change: make these four replacements. Each old text appears exactly once.
      1. Start item 2. Old: once NCode Review's review of the last push it asked for is in, and still judges
        New: once NCode Review's review of the last push it asked for is in, or, before any round, after a pass that finds no item once NCode Review's review of the pull request's head commit is in, and still judges
      2. Recommend the Merge. Old: once the run has had a round or that pass found items: every item is then fixed, declined, answered or put to me, and NCode Review's review of the last push the run asked it to review came back with nothing left to act on.
        New: once the run has had a round, that pass found items, or NCode Review's review of `<head commit>`, the pull request's head commit, which `gh pr view <number> --json headRefOid --jq .headRefOid` prints, is in, as the next sentence checks: every item is then fixed, declined, answered or put to me, and NCode Review's review of the last push the run asked it to review, or of `<head commit>`, came back with nothing left to act on.
      3. Recommend the Merge. Old: the whole sentence that starts A pass that finds no item before the run has had a round recommends nothing, on purpose: and ends until the wait limit passes. New, as one line:
        A pass that finds no item before the run has had a round reads that review: `gh api "repos/{owner}/{repo}/commits/<head commit>/check-runs?check_name=Code%20review" --jq '[.check_runs[] | select(.app.slug == "ncode-review" and .status == "completed" and .conclusion == "neutral" and ((.output.title // "Review") | startswith("Review") | not))] | length'`. NCode Review completes its `Code review` check run on a commit with the conclusion `neutral` and a title that counts its findings, such as `No findings`, once it has posted its review of that commit, and with a title that starts with `Review`, such as `Review skipped`, `Review budget used up` or `Review failed`, when it reviewed nothing there. When the command prints a number above 0, the review of `<head commit>` is in and, since the pass found no item, nothing it raised is left to act on: recommend the merge, unless a top-level comment on the pull request that starts with `Autopilot:` already recommends the merge at `<head commit>`. When it prints 0, or the call fails, recommend nothing: no review of `<head commit>` has arrived and nothing on the pull request has been answered yet, so the run keeps checking for comments and reviews until the wait limit passes, and reads the check run again at each later pass that finds no item.
        
      4. Recommend the Merge. Old: that says the pull request is ready to merge as far as this run can tell, why (the rounds so far, that each item was fixed, declined, answered or put to me, and, once the rounds passed
        New: that says the pull request is ready to merge at `<head commit>` as far as this run can tell, why (the rounds so far, that each item was fixed, declined, answered or put to me, or, with no round and no item, that NCode Review's review of `<head commit>` left nothing to act on, and, once the rounds passed
    • Done when: $f = Get-Content -Raw -LiteralPath workflow/templates/_run-feedback-body.md; $miss = @('or, before any round, after a pass that finds no item once NCode Review', 'once the run has had a round, that pass found items, or NCode Review', 'A pass that finds no item before the run has had a round reads that review', '/check-runs?check_name=Code%20review" --jq', '((.output.title // "Review") | startswith("Review") | not))] | length', 'already recommends the merge at ', 'when it reviewed nothing there', 'left nothing to act on, and, once the rounds passed') | Where-Object { -not $f.Contains($_) }; if ($miss -or $f.Contains('recommends nothing, on purpose') -or $f.Contains('once the run has had a round or that pass found items')) { $miss; exit 1 } else { exit 0 }

    [ ] 6. Recommend the merge after a clean first review in run-issues

    • Issue: /run-feedback never recommends the merge when the first review has no finding #688
    • Files: workflow/templates/run-issues.md (edit), workflow/templates/run-issues-copilot.md (edit)
    • Change: in Review the Pull Request item 9 of each file, replace once the entry has had a round or that check found NCode Review findings awaiting an answer: each finding is then fixed, declined, answered, left as a follow-up or left for me, and NCode Review's review of the last push the run asked it to review came back with nothing left to act on. (exactly once in each file) with this text, as one line:
      once the entry has had a round, that check found NCode Review findings awaiting an answer, or that check found nothing awaiting an answer and NCode Review's review of `<head commit>`, the pull request's head commit, which `gh pr view <number> --json headRefOid --jq .headRefOid` prints, is in: `gh api "repos/{owner}/{repo}/commits/<head commit>/check-runs?check_name=Code%20review" --jq '[.check_runs[] | select(.app.slug == "ncode-review" and .status == "completed" and .conclusion == "neutral" and ((.output.title // "Review") | startswith("Review") | not))] | length'` prints a number above 0, since NCode Review completes its `Code review` check run on a commit with the conclusion `neutral` and a title that counts its findings, such as `No findings`, once it has posted its review of that commit, and with a title that starts with `Review`, such as `Review skipped`, `Review budget used up` or `Review failed`, when it reviewed nothing there. Each finding is then fixed, declined, answered, left as a follow-up or left for me, and NCode Review's review of the last push the run asked it to review, or of `<head commit>`, came back with nothing left to act on. While that command prints 0, or the call fails, a check that finds nothing awaiting an answer before the entry's first round recommends nothing.
      
    • Done when: $bad = foreach ($p in 'workflow/templates/run-issues.md', 'workflow/templates/run-issues-copilot.md') { $t = Get-Content -Raw -LiteralPath $p; foreach ($x in 'or that check found nothing awaiting an answer and NCode Review', '/check-runs?check_name=Code%20review" --jq', '((.output.title // "Review") | startswith("Review") | not))] | length', 'when it reviewed nothing there. Each finding is then fixed', 'before the entry''s first round recommends nothing.') { if (-not $t.Contains($x)) { "$p missing $x" } }; if ($t.Contains('once the entry has had a round or that check found')) { "$p still has the old condition" } }; if ($bad) { $bad; exit 1 } else { exit 0 }

    [ ] 7. Regenerate the template's and the repository's workflow files

    • Issue: /run-feedback never recommends the merge when the first review has no finding #688
    • Files: template/.claude/commands/ (edit), template/.github/prompts/ (edit), template/.github/skills/ (edit), .claude/commands/ (edit), .github/prompts/ (edit), .github/skills/ (edit)
    • Change:
      • Run pwsh -NoProfile -File tools/Update-Template.ps1 from the repository root, and change nothing by hand.
      • Then git status --short must list, besides the files steps 1 to 6 changed, only files under the six folders above: run-feedback and run-issues in each folder.
      • When it lists any other file, such as one under .claude/agents/, .github/agents/ or template/.template/, stop, mark the step [?] and quote it.
      • Commit note: stage with git add -- template/.claude/commands template/.github/prompts template/.github/skills .claude/commands .github/prompts .github/skills.
    • Done when: $env:Path = [Environment]::GetEnvironmentVariable('Path','Machine') + ';' + [Environment]::GetEnvironmentVariable('Path','User'); . nvs.ps1 use 26 | Out-Null; $o = pwsh -NoProfile -File tests/Test-Template.ps1 -Only none 2>&1; $code = $LASTEXITCODE; if ($code -or -not ($o -match '^PASS workflow: run-feedback and run-issues recommend the merge after a first pass')) { exit 1 } else { exit 0 }

    [ ] 8. Describe the clean-first-review recommendation in USAGE.md

    • Issue: /run-feedback never recommends the merge when the first review has no finding #688
    • Files: USAGE.md (edit)
    • Change: right after the line that starts - After a pass that leaves every item fixed, declined, answered or put to you, once the bot's review of the last push it asked for is in, it recommends the merge, add this line, indented two spaces as a sub-bullet:
        - Before its first round, a pass that finds nothing to answer recommends the merge once the bot's review of the pull request's head commit is in, as its `Code review` check run shows, and recommends nothing while no review of that commit has arrived.
      
    • Done when: $l = Get-Content -LiteralPath USAGE.md; $i = [array]::FindIndex([string[]]$l, [Predicate[string]]{ param($x) $x.StartsWith('- After a pass that leaves every item fixed, declined, answered or put to you') }); if ($i -ge 0 -and $l[$i + 1].StartsWith(' - Before its first round, a pass that finds nothing to answer recommends the merge once the bot''s review of the pull request''s head commit is in')) { exit 0 } else { exit 1 }

    [ ] 9. Write the v0.154.2 changelog section

    • Issue: Update-Project.ps1's CodeQL note still prints the baseline as -Repo <name> -Owner <owner>, beside ADR-0068's -Repo <owner>/<name> #689 /run-feedback never recommends the merge when the first review has no finding #688
    • Files: CHANGELOG.md (edit)
    • Change:
      • Right below the line ## [Unreleased] (which has no entries), insert a blank line, then ## [0.154.2] - <date>, where <date> is what Get-Date -Format yyyy-MM-dd prints, then a blank line, ### Fixed, a blank line, and these two entries, each one line:
        - `.template/Update-Project.ps1` and `Adopt-Project.ps1` print the baseline command as `tools/Set-RepositoryBaseline.ps1 -Repo <owner>/<name>`, the form ADR-0068 gives, in the note they print when they add `.github/workflows/codeql.yml`, and the adoption in its command that protects the default branch too, so a run no longer prints the command in two forms ([#689](https://github.com/NCodeGroup/project-template/issues/689), [ADR-0068](template/docs/decisions/project-template/0068-a-repositorys-answers-are-its-manifest-and-the-baseline-needs-only-its-name.md)).
        - `/run-feedback` recommends the merge after a pass that finds nothing to answer before its first round once NCode Review's review of the pull request's head commit is in, as its `Code review` check run shows, so a pull request whose first review has no finding gets its recommendation; it still recommends nothing while no review of the head commit has arrived, and `/run-issues` does the same for a pull request whose first review has no finding ([#688](https://github.com/NCodeGroup/project-template/issues/688)).
        
        Keep one blank line between the last entry and the existing ## [0.154.1] - 2026-11-30 heading.
      • In the link reference definitions at the end of the file, replace [unreleased]: https://github.com/NCodeGroup/project-template/compare/v0.154.1...HEAD with [unreleased]: https://github.com/NCodeGroup/project-template/compare/v0.154.2...HEAD, and add the line [0.154.2]: https://github.com/NCodeGroup/project-template/compare/v0.154.1...v0.154.2 right after it, above the [0.154.1]: line.
    • Done when: $t = Get-Content -Raw -LiteralPath CHANGELOG.md; if ($t -match '(?m)^## \[Unreleased\]\r?\n\r?\n## \[0\.154\.2\] - \d{4}-\d{2}-\d{2}\r?\n\r?\n### Fixed\r?\n\r?\n- ' -and $t -match '\(\[#688\]\(https://github\.com/NCodeGroup/project-template/issues/688\)\)\.\r?\n\r?\n## \[0\.154\.1\] - 2026-11-30' -and $t.Contains('[#689](https://github.com/NCodeGroup/project-template/issues/689)') -and $t -match '(?m)^\[unreleased\]: https://github\.com/NCodeGroup/project-template/compare/v0\.154\.2\.\.\.HEAD\r?\n\[0\.154\.2\]: https://github\.com/NCodeGroup/project-template/compare/v0\.154\.1\.\.\.v0\.154\.2\r?\n\[0\.154\.1\]: ') { exit 0 } else { exit 1 }

    Review checklist

    • Run pwsh -NoProfile -File tests/Test-AdoptEdgeCases.ps1 and pwsh -NoProfile -File tests/Test-Adoption.ps1 -SkipDotnetBuild; both pass, with the ci-existing, plain and scaffold baseline-command checks showing -Repo <owner>/<name>.
    • Get-CodeQLWorkflowNote in template/.template/Update-Project.ps1 and Adopt-Project.ps1 are character for character equal, and neither function nor the adoption's protect command prints -Owner.
    • An update that adds codeql.yml on a GitHub origin prints -Repo <owner>/<name> in the CodeQL note and in the baseline note right after it, the same form twice.
    • In every generated run-feedback copy, a first pass with no item reads the head commit's Code review check run, recommends only when a posted NCode Review review is there, recommends nothing while none has arrived (a project without NCode Review never gets one this way, as before), and never recommends the same head commit twice across restarted runs.
    • In every generated run-issues copy, item 9's new condition reads as one sentence chain and keeps the default-branch hold that follows it.
    • The jq filter parses in gh: gh api "repos/NCodeGroup/Collections.Providers/commits/<head sha of #41>/check-runs?check_name=Code%20review" --jq '<the filter>' prints a number.
    • Run tests/e2e/Test-RunFeedback.ps1 by hand, as docs/tests.md asks after a change to /run-feedback.
    • After the release, a template update in NCodeGroup/Collections.Providers, NCodeGroup/Extensions.DataProtection, NCodeGroup/identity-platform or NCodeGroup/code-review, then /run-feedback on a pull request whose first review has no finding, posts the recommendation in its first pass.

    Follow-ups

    • Print the baseline command as -Repo / everywhere: template/.template/Test-MergeGate.ps1 (its -Repo $repoName -Owner $owner -WhatIf hint) and New-Project.ps1 (its "Run it again with:" warning) still print tools/Set-RepositoryBaseline.ps1 -Repo <name> -Owner <owner>, so a user still meets two forms of ADR-0068's one command; change both, and their tests in tests/Test-MergeGate.ps1 and tests/Test-NewProjectRemote.ps1.
  6. polewskm commented on Dec 1, 2026

    @polewskm
    CollaboratorAuthor

    Also seen in NCodeGroup/brand#55 (Update from project-template v0.154.0): NCode Review's first review said Verdict: ✅ Approve with no finding in the project's own files and approved head b1096a6, so a first pass had no item and no round. The run reached a recommendation only because the pull request was retargeted to v0.154.1, whose push and /review gave it a round. NCodeGroup/brand's next /run-feedback can check the fix too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions