Skip to content

fix(#83): use correct variable in new issues confidence gate#84

Merged
ralphbean merged 1 commit into
mainfrom
agent/83-fix-scribe-confidence-gate
Jul 9, 2026
Merged

fix(#83): use correct variable in new issues confidence gate#84
ralphbean merged 1 commit into
mainfrom
agent/83-fix-scribe-confidence-gate

Conversation

@fullsend-ai-coder

Copy link
Copy Markdown
Contributor

In the new-issues loop of post-scribe.sh, line 376 used ${TOPIC} (set only in the existing-issues loop) instead of ${TITLE} (the loop-local variable). In new_issues_only mode, TOPIC is never assigned, causing an unbound variable crash under set -euo pipefail when a new issue has an invalid confidence value.

Change gate_reject call on line 376 from ${TOPIC} to ${TITLE}, matching the correct usage on line 380 in the same loop. Add a test case that exercises new_issues_only mode with a non-numeric confidence value, which crashed before this fix and now produces a clean gate rejection.

Note: pre-commit could not run shellcheck hook (sandbox network restriction). The low-confidence-rejected test has a pre-existing failure due to missing bc in sandbox.


Closes #83

Post-script verification

  • Branch is not main/master (agent/83-fix-scribe-confidence-gate)
  • Secret scan passed (gitleaks — e017eaa080f40ab8cc347b589b92c0847d571b28..HEAD)
  • Pre-commit hooks passed (authoritative run on runner)
  • Tests ran inside sandbox

In the new-issues loop of post-scribe.sh, line 376 used
${TOPIC} (set only in the existing-issues loop) instead
of ${TITLE} (the loop-local variable). In new_issues_only
mode, TOPIC is never assigned, causing an unbound variable
crash under set -euo pipefail when a new issue has an
invalid confidence value.

Change gate_reject call on line 376 from ${TOPIC} to
${TITLE}, matching the correct usage on line 380 in the
same loop. Add a test case that exercises new_issues_only
mode with a non-numeric confidence value, which crashed
before this fix and now produces a clean gate rejection.

Note: pre-commit could not run shellcheck hook (sandbox
network restriction). The low-confidence-rejected test
has a pre-existing failure due to missing bc in sandbox.

Closes #83
@fullsend-ai-coder
fullsend-ai-coder Bot requested a review from a team as a code owner July 9, 2026 14:22
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown

Functional tests did not run

Functional tests run automatically for org/repo members and collaborators on pull requests.

For other contributors, a maintainer must add the ok-to-test label after the latest push.

@ralphbean
ralphbean added this pull request to the merge queue Jul 9, 2026
Merged via the queue into main with commit ed9c9cb Jul 9, 2026
11 checks passed
@fullsend-ai-retro

fullsend-ai-retro Bot commented Jul 9, 2026

Copy link
Copy Markdown

🤖 Finished Retro · ✅ Success · Started 6:36 PM UTC · Completed 6:43 PM UTC
Commit: d2abdbd · View workflow run →

@fullsend-ai-retro

Copy link
Copy Markdown

PR #84 fixed a copy-paste variable bug in post-scribe.sh (${TOPIC}${TITLE}) that was identified by the review agent on PR #10 but merged under a COMMENTED verdict. The retro agent on PR #10 filed issue #83, the code agent created PR #84 with a correct 1-line fix and 1 new test case, and human ralphbean approved and merged — completing the full retro→issue→code→merge loop in ~5 hours. The code change is minimal, correct, and well-tested. CI (script-test, test, commit-lint, DCO) all passed. One improvement proposal: a latent security-gate bypass in the same file (echo flag misinterpretation) was identified by the review agent on PR #10 but never tracked as an issue.

Proposals filed

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 copy-paste variable bug in post-scribe.sh new issues confidence gate

1 participant