Skip to content

feat: implement issue #821 — Fleet stubs for idea-triage and idea-enhancer - #829

Merged
don-petry merged 2 commits into
mainfrom
dev-lead/issue-821-20260620-0519
Jun 20, 2026
Merged

feat: implement issue #821 — Fleet stubs for idea-triage and idea-enhancer#829
don-petry merged 2 commits into
mainfrom
dev-lead/issue-821-20260620-0519

Conversation

@don-petry

@don-petry don-petry commented Jun 20, 2026

Copy link
Copy Markdown
Collaborator

Closes #821

Implemented by dev-lead agent. Please review.

Summary by CodeRabbit

  • New Features

    • Workflows now support enhancing and triaging Ideas in external repositories through new workflow dispatch inputs.
    • Improved concurrency control allows different target repositories to run simultaneously without interfering with each other.
  • Tests

    • Added comprehensive test coverage validating cross-repository functionality for both enhancement and triage workflows.

@don-petry
don-petry requested a review from a team as a code owner June 20, 2026 05:30
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@don-petry

Copy link
Copy Markdown
Collaborator Author

Dev-Lead — review-changes (no-changes)

No changes were needed for this PR.

@don-petry
don-petry enabled auto-merge (squash) June 20, 2026 05:30
@donpetry-bot

Copy link
Copy Markdown
Contributor

Advisory bots were rate-limited; auto-approval is withheld until they recover. pr-review-sweep will re-review this PR after 2026-06-20T06:31:19Z.

@don-petry
don-petry disabled auto-merge June 20, 2026 05:31
@don-petry

Copy link
Copy Markdown
Collaborator Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
Issues addressed: 0
- Quality Gate passed with no new issues
Files changed: None (no fixes required)
Skipped (informational): 0
```
The PR is already passing all quality gates and security checks. There are no actionable issues to address.

@don-petry
don-petry enabled auto-merge (squash) June 20, 2026 05:31
@coderabbitai

coderabbitai Bot commented Jun 20, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: f6a0b606-e7c8-443b-b5a8-30b4bb800a4b

📥 Commits

Reviewing files that changed from the base of the PR and between d5bbbae and 49270e4.

📒 Files selected for processing (4)
  • .github/workflows/idea-enhancer.yml
  • .github/workflows/idea-triage.yml
  • tests/test_idea_enhancer.bats
  • tests/test_idea_triage.bats

📝 Walkthrough

Walkthrough

Both idea-enhancer.yml and idea-triage.yml gain an optional target_repo dispatch input. Concurrency groups are now keyed per target repo, and a computed TARGET_GH_TOKEN conditionally selects GITHUB_TOKEN (self) or GH_PAT_WORKFLOWS (cross-repo). Steps use env.TARGET_GH_TOKEN and the resolved env.REPO. Bats suites are extended with cross-repo assertions for both workflows.

Changes

Fleet parameterization of idea-triage and idea-enhancer

Layer / File(s) Summary
Dispatch input, concurrency keying, and env var derivation
.github/workflows/idea-enhancer.yml, .github/workflows/idea-triage.yml
Both workflows add an optional target_repo workflow_dispatch input, change their concurrency group to include the resolved target repo, and introduce REPO and TARGET_GH_TOKEN env vars that select between GITHUB_TOKEN and GH_PAT_WORKFLOWS.
Step-level token and REPO variable wiring
.github/workflows/idea-enhancer.yml, .github/workflows/idea-triage.yml
Gather and enhance/triage steps use env.TARGET_GH_TOKEN for authentication; LLM prompts reference env.REPO; bash invocations for post-enhancement.sh and upsert-queue.sh export REPO="$REPO" instead of the hardcoded github.repository expression.
Bats cross-repo test coverage
tests/test_idea_enhancer.bats, tests/test_idea_triage.bats
Adds a logging gh mock and new tests asserting that gather-candidates.sh, post-enhancement.sh, gather-ideas, and upsert-queue issue calls against the target repo (acme/widgets), exclude .github-private, and produce correct context repo fields.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dev-lead/issue-821-20260620-0519

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@don-petry
don-petry disabled auto-merge June 20, 2026 05:32
@don-petry

Copy link
Copy Markdown
Collaborator Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
- No review threads exist (`[]` in review states)
- No Tier 1 blockers
## Conclusion
This is an **informational/administrative message** about CodeRabbit's billing and rate limits, not a code quality or security issue. There are no actionable code fixes to apply.
The PR itself is healthy — all CI checks pass, including:
- ShellCheck, SonarCloud, CodeQL, Lint, Agent Security Scan ✓
- All workflow compilations, BATS tests ✓
**No changes needed.** The PR is ready to merge once CodeRabbit's rate limit resets (or the org enables usage-based billing). If a code review is desired before merge, you can:
1. Wait ~48 minutes for the rate limit to reset, then push a new commit or comment `@coderabbitai review`
2. Or enable the CodeRabbit review add-on in billing settings immediately

@don-petry
don-petry enabled auto-merge (squash) June 20, 2026 05:32
@coderabbitai

coderabbitai Bot commented Jun 20, 2026

Copy link
Copy Markdown

Your plan includes PR reviews subject to rate limits. More reviews will be available in 47 minutes and 6 seconds.

@don-petry
don-petry disabled auto-merge June 20, 2026 05:33
@don-petry

Copy link
Copy Markdown
Collaborator Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
Issues addressed: 0
- Rate limit notification: No action required — this is informational. All CI checks pass.
Files changed: None
Skipped (informational): 1
```
The PR is ready. No code changes are needed in response to this bot message. If you'd like me to perform a different task on this PR (such as review the actual changes, validate the commit, or prepare it for merge), let me know.

@don-petry
don-petry enabled auto-merge (squash) June 20, 2026 05:33

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request adds integration tests to verify cross-repository parameterization for both the idea enhancer and idea triage workflows. The new tests ensure that when a non-self target repository is specified, candidates are gathered from, and comments or tracking issues are created in, that target repository rather than the default private repository. I have no feedback to provide as there are no review comments.

@don-petry
don-petry disabled auto-merge June 20, 2026 05:35
@don-petry

Copy link
Copy Markdown
Collaborator Author

Dev-Lead — fix-reviews (no-changes)

Agent reasoning
Addressed 0 threads:
(no open threads)
Test verification: skipped — no code changes were made
Files changed: none
```

@don-petry
don-petry enabled auto-merge (squash) June 20, 2026 05:35

@donpetry-bot donpetry-bot left a comment

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.

Automated review — APPROVED ✓

Risk: LOW
Reviewed commit: 96fc16a350cf24e8fe80bb21da8c5ad272600013
Review mode: triage-approved (single reviewer)

Summary

Parameterizes idea-triage.yml and idea-enhancer.yml on a new optional target_repo workflow_dispatch input so the central workflows can triage/enhance a non-self fleet repo. Concurrency is keyed per target repo, and a TARGET_GH_TOKEN selects GITHUB_TOKEN for the self path or GH_PAT_WORKFLOWS for cross-repo writes (since GITHUB_TOKEN cannot write to other repos). REPO threads through gather/post/upsert scripts and the Claude prompts. Adds bats coverage asserting REPO flows to every gh/GraphQL call for a non-self target, with gh fully stubbed (no network).

Linked issue analysis

Closes #821. AC#1 (target_repo input + cross-repo token) and AC#4 (bats for a non-self target on both workflows) are satisfied here. AC#2 (caller stubs in standards/workflows/) lives in the public petry-projects/.github repo per the issue's two-repo split, so it is correctly out of scope for this PR. AC#3 (queue issue created in the target repo) is exercised by the new upsert-queue bats test; the script already accepts REPO, so no script change was required.

Findings

  • Token selection is sound: self path uses GITHUB_TOKEN (job already grants issues:write for the queue upsert), cross-repo uses GH_PAT_WORKFLOWS. Matches the established cross-repo convention.
  • target_repo originates from workflow_dispatch (write-access actors only) and is used only in the concurrency-group key, a string-comparison token ternary, and env vars — not interpolated into any run: shell command, so no injection surface.
  • Tests stub gh and assert no '.github-private' leakage on non-self runs; they avoid network. Good negative assertions.
  • Nit (non-blocking): the inline comments cite initiative-planner.yml as the 'same pattern', but the planner is a self-only, discussion-keyed flow and does not use the identical TARGET_GH_TOKEN ternary. The logic here is nonetheless correct; consider softening the comparison wording.
  • MCP run_secret_scanning was not executable in this context (permission not granted); skipped per protocol. No literal secrets in the diff — only Actions secret references and a fake GH_TOKEN=x test value.

CI status

All required checks green: Lint/ShellCheck, bats/unit-tests, CodeQL (actions+python), SonarCloud (Quality Gate passed, 0 new issues), gitleaks, Agent Security Scan, Compile agentic workflows, validate-agent-profiles. Gemini reviewed with no feedback. CodeRabbit and Codex were rate-limited (informational only). mergeStateStatus BLOCKED solely on the required org-leads human review (REVIEW_REQUIRED), which is the expected human gate.


Reviewed automatically by the PR-review agent (single-reviewer agent). Reply if you need a human review.

@sonarqubecloud

Copy link
Copy Markdown

@don-petry
don-petry merged commit 5b6e39d into main Jun 20, 2026
27 of 28 checks passed
@don-petry
don-petry deleted the dev-lead/issue-821-20260620-0519 branch June 20, 2026 06:46
@donpetry-bot

Copy link
Copy Markdown
Contributor

Advisory bots were rate-limited; auto-approval is withheld until they recover. pr-review-sweep will re-review this PR after 2026-06-20T07:49:07Z.

don-petry added a commit that referenced this pull request Aug 2, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 3, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 3, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 3, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 7, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 8, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 8, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 8, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
don-petry added a commit that referenced this pull request Aug 8, 2026
…ancer (#829)

Co-authored-by: donpetry-bot <281750570+donpetry-bot@users.noreply.github.com>
Co-authored-by: Don Petry Bot <donpetry+bot@gmail.com>
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.

Fleet stubs for idea-triage and idea-enhancer

2 participants