feat(triage): add Jira Cloud tracker support - #827
Conversation
|
🤖 Finished Review · ✅ Success · Started 3:08 AM UTC · Completed 3:28 AM UTC Commit: |
ReviewFindingsHigh
Medium
Low
Info
Next steps:
Previous runReviewFindingsHigh
Medium
Low
Next steps:
Previous run (2)ReviewFindingsHigh
Medium
Low
Next steps:
Previous run (3)ReviewFindingsHigh
Low
Next steps:
Previous run (4)ReviewFindingsHigh
Medium
Low
Next steps:
Previous run (5)ReviewFindingsHigh
Medium
Low
Next steps:
Previous run (6)ReviewFindingsHigh
Medium
Low
Next steps:
Previous run (7)ReviewFindingsHigh
Medium
Low
Next steps:
Previous run (8)ReviewFindingsHigh
Medium
Low
Next steps:
Previous run (9)ReviewFindingsHigh
Medium
Low
Labels: PR adds Jira Cloud tracker support to the triage agent with security-relevant credential handling changes. Next steps:
|
|
🤖 Finished Fix · ✅ Success · Started 3:29 AM UTC · Completed 3:39 AM UTC Commit: |
🔧 Fix agent — iteration 1 (bot-triggered)Addressed 6 of 11 review findings: added missing Jira transition env vars to harness env.runner (bug fix), reverted docs/LOCAL.md from rejected tracker terminology to forge, documented dual-format schema fields, and removed .gitignore scope creep. Disagreed with 5 findings: the two high/medium secret-exposure findings require architectural credential provider work (acknowledged by PR author as priority TODO), and three low-severity findings concern protected-path files or informational observations about existing patterns. Fixed (6):
Disagreed (5):
Tests: passedNext steps:
|
- Add missing JIRA_DUPLICATE_TRANSITION, JIRA_NOT_PLANNED_TRANSITION, JIRA_SPLIT_TRANSITION to forge.jira.env.runner in harness/triage.yaml so the runner passes transition vars to the post-script - Revert docs/triage.md heading and terminology from "Multi-tracker" back to "Multi-forge" — the tracker/forge harness-split was rejected upstream (fullsend-ai/fullsend#6237) and the harness still uses forge: as the top-level key - Fix LOCAL.md Jira walkthrough to use FULLSEND_FORGE instead of FULLSEND_TRACKER - Add description fields to triage-result schema documenting the dual format for duplicate_of (integer vs Jira key) and repo (org/repo path vs bare Jira project key) - Remove .gitignore scope-creep additions (.claude, openspec) unrelated to Jira tracker support Addresses review feedback on #827
|
🤖 Finished Review · ✅ Success · Started 3:40 AM UTC · Completed 3:59 AM UTC Commit: |
|
🤖 Finished Fix · ✅ Success · Started 4:00 AM UTC · Completed 4:10 AM UTC Commit: |
Update docs/triage.md and LOCAL.md to reference FULLSEND_TRACKER as the primary environment variable (with FULLSEND_FORGE as backward-compatible fallback), matching what the harness and scripts actually set. - docs/triage.md: "Multi-forge support" section and migration notes now name FULLSEND_TRACKER and note the FULLSEND_FORGE fallback. - LOCAL.md: Jira local testing instructions updated to use FULLSEND_TRACKER instead of FULLSEND_FORGE. Addresses review feedback on #827
🔧 Fix agent — iteration 2 (bot-triggered)Addressed 3 of 12 review findings: updated docs/triage.md and LOCAL.md to reference FULLSEND_TRACKER as the canonical env var (with FULLSEND_FORGE as backward-compatible fallback), fixing the documentation-vs-code inconsistency flagged in findings 4, 6, and 9. Disagreed with 9 findings: the two secret-exposure findings require architectural credential provider work (flagged by PR author as priority TODO), the protected-path finding requires human action to link an issue, and remaining findings concern protected-path files, intentional schema changes already documented in iteration 1, or informational observations about existing patterns. Fixed (3):
Disagreed (9):
Tests: passedNext steps:
|
|
🤖 Finished Review · ✅ Success · Started 4:11 AM UTC · Completed 4:30 AM UTC Commit: |
|
🤖 Finished Fix · ✅ Success · Started 4:31 AM UTC · Completed 4:42 AM UTC Commit: |
- LOCAL.md: use FULLSEND_TRACKER consistently in both GitHub and Jira local-testing sections (was FULLSEND_FORGE in GitHub section) - jira-triage-ops.lib.sh: rename target_project → target_repo in tracker_create_issue() to match GitHub/GitLab interface naming - jira-triage-ops.lib.sh: add defense-in-depth warning when tracker_parse_issue_url() would overwrite a pre-set JIRA_BASE_URL that differs from the ISSUE_URL host - post-triage-test.sh: add Jira test coverage for sufficient (with category-based label dispatch and TRIAGE_AUTO_CODE gating), in-progress (sticky comment, pr-open label, label cleanup), and question (comment, label, cleanup) actions Addresses review feedback on #827
🔧 Fix agent — iteration 3 (bot-triggered)Addressed 4 of 10 review findings with code fixes: LOCAL.md env var consistency, tracker_create_issue naming alignment, JIRA_BASE_URL defense-in-depth warning, and 10 new Jira test cases for sufficient/in-progress/question actions. Disagreed with 6 findings (2 secret-exposure requiring architectural change tracked as PR TODO, 2 breaking-schema already addressed in prior iterations, 1 design-direction broader than this PR, 1 sandbox-escape observational). Fixed (4):
Disagreed (6):
Tests: passed
Decision points
Next steps:
|
|
🤖 Finished Review · ✅ Success · Started 4:43 AM UTC · Completed 5:04 AM UTC Commit: |
|
🤖 Finished Fix · ✅ Success · Started 5:05 AM UTC · Completed 5:16 AM UTC Commit: |
- Fix logic error in tracker_verify_labels_stripped: replace fragile IFS=',' comma-split with jq line-by-line iteration, avoiding incorrect results when Jira labels contain commas (finding: logic-error) - Harden tracker_parse_issue_url: reject JIRA_BASE_URL mismatches with an error instead of warning-and-overwrite, preventing API call redirection to a different tenant (finding: data-exposure) - Add jira-duplicate-self-reference-fails test: verify duplicate_of matching the current ISSUE_NUMBER is rejected for Jira issue keys, matching existing GitHub integer self-reference coverage (finding: test-inadequate) - Add jira-label-put-failure-propagates test: verify error propagation when label PUT API calls fail (finding: test-inadequate) - Rebuild bundled scripts to reflect lib changes Addresses review feedback on #827
🔧 Fix agent — iteration 4 (bot-triggered)Addressed 4 of 12 review findings with code changes: fixed logic error in label parsing, hardened JIRA_BASE_URL mismatch handling, added Jira self-reference duplicate test, and added label API error propagation test. Disagreed with 8 findings: 5 reference protected paths (harness/, skills/, policies/) requiring human oversight, 2 were already addressed by prior iterations (schema descriptions), and 1 is an informational note with no code change requested. Strategy escalation (iteration 4): focused on code-level bugs and missing test coverage that prior documentation-focused iterations missed. Fixed (4):
Disagreed (8):
Tests: passed
Decision points
Next steps:
|
|
🤖 Finished Review · ✅ Success · Started 5:17 AM UTC · Completed 5:34 AM UTC Commit: |
|
🤖 Finished Fix · ✅ Success · Started 5:36 AM UTC · Completed 5:45 AM UTC Commit: |
- README.md: add Jira Cloud to platform listing - docs/review.md: add jira to issue-labels skill per-forge variants - docs/network-policy.md: mention Jira forge policy allows curl - agents/triage.md: update curl comment and prerequisites.create repo field to include Jira project key format Addresses review feedback on #827
waynesun09
left a comment
There was a problem hiding this comment.
Approving. Reviewed the Jira tracker support end to end, and independently verified the follow-up commits (d05a66c, 6f2b641, 744711f) that close out the review findings.
Verified before approving
- All four required checks green on
744711f:script-test,test,commit-lint,functional-tests-complete. - Full test suites pass on both Linux (podman, ubuntu 24.04) and macOS 26 host:
post-triage,pre-triage,validate-output-schema,labels. make check-bundleclean (generated bundles in sync with sources);shellcheck -x -e SC1091,SC2001,SC2016clean;hack/lint-agent-docsreportstriage.md: OK.- Every behavioural test added in the follow-ups was mutation-checked — each one fails when its fix is reverted.
Substantive fixes made after the last automated fix round
/rest/api/3/search/jqlreturns onlyidandkeyunlessfieldsis passed. The endpoint migration had left it off, so duplicate detection returned opaque keys with nothing to compare — a silent 200 in place of the old loud 410. Now requestsfields=summary,status,labelsat all four call sites.tracker_verify_labels_strippedtreated an unparseable response body as "no labels remaining" and reported the reset verified; now fails via theVERIFY_FAILEDsentinel the GitHub/GitLab implementations use.tracker_create_issueannounced.../browse/nullwhen a 201 carried no.key; now reported as a failed create.- The deferred-label path shelled out to
gh label create --repo <jira-project-key>on Jira runs; now skipped, since Jira has no label registry. - Portability: the test harness's mock
yqused a GNU-only nested-bracesedthat BSD/macOS rejects, silently emptying the allowlist and failing everyallow_targetstest on macOS; and the Jira comment marker'sdate +%s%Nhad no fallback for adate(1)lacking%N.
Knowingly deferred, not oversights
JIRA_TOKENinenv.sandbox— the architectural host-side credential-provider work the PR body already tracks as a TODO. Real, and out of scope here.- Schema widening of
duplicate_ofandrepo— intentional and documented. - The
forge_ensure_labeltracker guard — declining the polymorphic-interface suggestion per AGENTS.md §2 ("no abstractions for single-use code paths"): it has exactly one call site, andlabels.lib.shis shared infrastructure whose current name is the deliberate result of #479.
Note the functional-tests (triage) failures seen on earlier heads were an eval-harness flake, not this PR: the case artifacts show provider create "vertex-ai" failed: unsupported provider type or profile, a race during sandbox provider setup that kills a different random subset of cases each run before any triage code executes. It passed cleanly on 744711f.
|
🤖 Finished Retro · ✅ Success · Started 10:12 PM UTC · Completed 10:25 PM UTC Commit: |
Retro: PR #827 — Jira Cloud tracker supportPR #827 added Jira Cloud as a third forge to the triage harness (24 files, 2488 additions, 301 deletions). The workflow was resource-intensive: 10 bot reviews (all CHANGES_REQUESTED), 7 fix iterations (3 immediate failures), before human reviewer waynesun09 approved after making 3 manual commits. Wall-clock time: ~19 hours across two days. TimelineDay 1 (Aug 17, 03:05–06:06 UTC) — Automated loop:
Day 2 (Aug 18, 17:22–22:10 UTC) — Human-driven resolution:
Key finding: Correctness gap in review agentThe review agent's correctness sub-agent (opus-tier) failed to detect 5+ behavioral bugs in a new 349-line API client shell script across 10 iterations, while its output was dominated by governance findings. Human reviewer waynesun09 found the bugs in one pass using an independent AI review (Grok). The missed bugs included: missing required API fields causing silent data loss, treating unparseable responses as success, null value propagation to user-facing URLs, wrong-platform tool calls, and BSD/macOS incompatibility. See Proposal 1. Evidence supporting existing open issues
Proposals filed
|
- Add missing JIRA_DUPLICATE_TRANSITION, JIRA_NOT_PLANNED_TRANSITION, JIRA_SPLIT_TRANSITION to forge.jira.env.runner in harness/triage.yaml so the runner passes transition vars to the post-script - Revert docs/triage.md heading and terminology from "Multi-tracker" back to "Multi-forge" — the tracker/forge harness-split was rejected upstream (fullsend-ai/fullsend#6237) and the harness still uses forge: as the top-level key - Fix LOCAL.md Jira walkthrough to use FULLSEND_FORGE instead of FULLSEND_TRACKER - Add description fields to triage-result schema documenting the dual format for duplicate_of (integer vs Jira key) and repo (org/repo path vs bare Jira project key) - Remove .gitignore scope-creep additions (.claude, openspec) unrelated to Jira tracker support Addresses review feedback on #827
Update docs/triage.md and LOCAL.md to reference FULLSEND_TRACKER as the primary environment variable (with FULLSEND_FORGE as backward-compatible fallback), matching what the harness and scripts actually set. - docs/triage.md: "Multi-forge support" section and migration notes now name FULLSEND_TRACKER and note the FULLSEND_FORGE fallback. - LOCAL.md: Jira local testing instructions updated to use FULLSEND_TRACKER instead of FULLSEND_FORGE. Addresses review feedback on #827
- LOCAL.md: use FULLSEND_TRACKER consistently in both GitHub and Jira local-testing sections (was FULLSEND_FORGE in GitHub section) - jira-triage-ops.lib.sh: rename target_project → target_repo in tracker_create_issue() to match GitHub/GitLab interface naming - jira-triage-ops.lib.sh: add defense-in-depth warning when tracker_parse_issue_url() would overwrite a pre-set JIRA_BASE_URL that differs from the ISSUE_URL host - post-triage-test.sh: add Jira test coverage for sufficient (with category-based label dispatch and TRIAGE_AUTO_CODE gating), in-progress (sticky comment, pr-open label, label cleanup), and question (comment, label, cleanup) actions Addresses review feedback on #827
- Fix logic error in tracker_verify_labels_stripped: replace fragile IFS=',' comma-split with jq line-by-line iteration, avoiding incorrect results when Jira labels contain commas (finding: logic-error) - Harden tracker_parse_issue_url: reject JIRA_BASE_URL mismatches with an error instead of warning-and-overwrite, preventing API call redirection to a different tenant (finding: data-exposure) - Add jira-duplicate-self-reference-fails test: verify duplicate_of matching the current ISSUE_NUMBER is rejected for Jira issue keys, matching existing GitHub integer self-reference coverage (finding: test-inadequate) - Add jira-label-put-failure-propagates test: verify error propagation when label PUT API calls fail (finding: test-inadequate) - Rebuild bundled scripts to reflect lib changes Addresses review feedback on #827
- README.md: add Jira Cloud to platform listing - docs/review.md: add jira to issue-labels skill per-forge variants - docs/network-policy.md: mention Jira forge policy allows curl - agents/triage.md: update curl comment and prerequisites.create repo field to include Jira project key format Addresses review feedback on #827
harness/triage.yaml was setting FULLSEND_TRACKER in env.runner/env.sandbox for all three forge blocks, contradicting design.md's Decision 1/3 (the harness should only ever set FULLSEND_FORGE; FULLSEND_TRACKER is an internal script-layer fallback for forward-compatibility with a possible future harness key, not something the harness itself sets). A prior automated review/fix pass on PR #827 caught the symptom but "fixed" it by flipping docs to describe FULLSEND_TRACKER as canonical instead. This reverts that framing and fixes the actual harness bug: all six FULLSEND_TRACKER literals become FULLSEND_FORGE, and docs/triage.md and LOCAL.md are corrected to match. Assisted-by: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Ralph Bean <rbean@redhat.com>
Align Jira skill naming with the established convention used by github-forge (name: github) and gitlab-forge (name: gitlab). Renames the directory from skills/jira-tracker to skills/jira-forge, sets the frontmatter name to 'jira', and updates all references in the harness, policy comments, and docs. Also adds the jira issue-labels variant to the per-forge skill listing in docs/triage.md. Addresses review feedback on #827
- Migrate all Jira search API calls from deprecated /rest/api/3/search to /rest/api/3/search/jql (Atlassian removed the old endpoint 2025-05-01). Add --fail-with-body and document nextPageToken pagination. - Fix tracker_create_issue ADF body to split multi-line text into separate paragraph nodes with hardBreak nodes for single newlines, instead of flattening into a single text node that violates ADF validation. - Document Jira-key form of duplicate_of in agents/triage.md so the agent emits issue keys (e.g. "PROJ-45") instead of bare integers on Jira, making the self-duplicate guard effective. - Strip trailing slash from JIRA_BASE_URL before tenant comparison so copy-pasted URLs with trailing slash don't brick every run. - Fix rebase conflict: use tracker_add_label (not forge_add_label) for deferred label application, matching the tracker_* naming used by all three forge lib files on this branch. Addresses review feedback on #827
- Add missing JIRA_DUPLICATE_TRANSITION, JIRA_NOT_PLANNED_TRANSITION, JIRA_SPLIT_TRANSITION to forge.jira.env.runner in harness/triage.yaml so the runner passes transition vars to the post-script - Revert docs/triage.md heading and terminology from "Multi-tracker" back to "Multi-forge" — the tracker/forge harness-split was rejected upstream (fullsend-ai/fullsend#6237) and the harness still uses forge: as the top-level key - Fix LOCAL.md Jira walkthrough to use FULLSEND_FORGE instead of FULLSEND_TRACKER - Add description fields to triage-result schema documenting the dual format for duplicate_of (integer vs Jira key) and repo (org/repo path vs bare Jira project key) - Remove .gitignore scope-creep additions (.claude, openspec) unrelated to Jira tracker support Addresses review feedback on fullsend-ai#827
Update docs/triage.md and LOCAL.md to reference FULLSEND_TRACKER as the primary environment variable (with FULLSEND_FORGE as backward-compatible fallback), matching what the harness and scripts actually set. - docs/triage.md: "Multi-forge support" section and migration notes now name FULLSEND_TRACKER and note the FULLSEND_FORGE fallback. - LOCAL.md: Jira local testing instructions updated to use FULLSEND_TRACKER instead of FULLSEND_FORGE. Addresses review feedback on fullsend-ai#827
- LOCAL.md: use FULLSEND_TRACKER consistently in both GitHub and Jira local-testing sections (was FULLSEND_FORGE in GitHub section) - jira-triage-ops.lib.sh: rename target_project → target_repo in tracker_create_issue() to match GitHub/GitLab interface naming - jira-triage-ops.lib.sh: add defense-in-depth warning when tracker_parse_issue_url() would overwrite a pre-set JIRA_BASE_URL that differs from the ISSUE_URL host - post-triage-test.sh: add Jira test coverage for sufficient (with category-based label dispatch and TRIAGE_AUTO_CODE gating), in-progress (sticky comment, pr-open label, label cleanup), and question (comment, label, cleanup) actions Addresses review feedback on fullsend-ai#827
- Fix logic error in tracker_verify_labels_stripped: replace fragile IFS=',' comma-split with jq line-by-line iteration, avoiding incorrect results when Jira labels contain commas (finding: logic-error) - Harden tracker_parse_issue_url: reject JIRA_BASE_URL mismatches with an error instead of warning-and-overwrite, preventing API call redirection to a different tenant (finding: data-exposure) - Add jira-duplicate-self-reference-fails test: verify duplicate_of matching the current ISSUE_NUMBER is rejected for Jira issue keys, matching existing GitHub integer self-reference coverage (finding: test-inadequate) - Add jira-label-put-failure-propagates test: verify error propagation when label PUT API calls fail (finding: test-inadequate) - Rebuild bundled scripts to reflect lib changes Addresses review feedback on fullsend-ai#827
- README.md: add Jira Cloud to platform listing - docs/review.md: add jira to issue-labels skill per-forge variants - docs/network-policy.md: mention Jira forge policy allows curl - agents/triage.md: update curl comment and prerequisites.create repo field to include Jira project key format Addresses review feedback on fullsend-ai#827
harness/triage.yaml was setting FULLSEND_TRACKER in env.runner/env.sandbox for all three forge blocks, contradicting design.md's Decision 1/3 (the harness should only ever set FULLSEND_FORGE; FULLSEND_TRACKER is an internal script-layer fallback for forward-compatibility with a possible future harness key, not something the harness itself sets). A prior automated review/fix pass on PR fullsend-ai#827 caught the symptom but "fixed" it by flipping docs to describe FULLSEND_TRACKER as canonical instead. This reverts that framing and fixes the actual harness bug: all six FULLSEND_TRACKER literals become FULLSEND_FORGE, and docs/triage.md and LOCAL.md are corrected to match. Assisted-by: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Ralph Bean <rbean@redhat.com>
Align Jira skill naming with the established convention used by github-forge (name: github) and gitlab-forge (name: gitlab). Renames the directory from skills/jira-tracker to skills/jira-forge, sets the frontmatter name to 'jira', and updates all references in the harness, policy comments, and docs. Also adds the jira issue-labels variant to the per-forge skill listing in docs/triage.md. Addresses review feedback on fullsend-ai#827
- Migrate all Jira search API calls from deprecated /rest/api/3/search to /rest/api/3/search/jql (Atlassian removed the old endpoint 2025-05-01). Add --fail-with-body and document nextPageToken pagination. - Fix tracker_create_issue ADF body to split multi-line text into separate paragraph nodes with hardBreak nodes for single newlines, instead of flattening into a single text node that violates ADF validation. - Document Jira-key form of duplicate_of in agents/triage.md so the agent emits issue keys (e.g. "PROJ-45") instead of bare integers on Jira, making the self-duplicate guard effective. - Strip trailing slash from JIRA_BASE_URL before tenant comparison so copy-pasted URLs with trailing slash don't brick every run. - Fix rebase conflict: use tracker_add_label (not forge_add_label) for deferred label application, matching the tracker_* naming used by all three forge lib files on this branch. Addresses review feedback on fullsend-ai#827
Summary
forge.jirablock toharness/triage.yamlwith the same decision surface (comment, label, close/transition, cross-project issue creation) already supported for GitHub and GitLab.scripts/lib/jira-triage-ops.lib.shimplements thetracker_*interface against the Jira Cloud REST API, plusenv/jira/,policies/jira/,skills/jira-tracker, andskills/issue-labels/jira.schemas/triage-result.schema.jsonto accept Jira-shaped identifiers (issue keys, bare project keys, Jira URLs) alongside the existing GitHub/GitLab patterns.Priority TODO before merge
Figure out better handling for
JIRA_TOKENso we don't put the raw token in the sandbox. UnlikeGH_TOKEN(a short-lived, run-scoped credential),JIRA_TOKENis a long-lived Jira Cloud PAT, and it's currently passed intoharness/triage.yaml'sforge.jira.env.sandboxblock so the read-only curl commands inskills/jira-trackercan authenticate. That's a materially worse exposure than the GitHub precedent this was copied from. OpenShell reportedly supports registering a credential provider that injects a placeholder token into the sandbox and swaps it for the real credential at network egress — need to verify that mechanism against the actual OpenShell policy schema and migrate to it before this ships. Tracked in this change'sopenspec/changes/add-jira-tracker-support/design.md(Risks / Open Questions) locally, not checked in.Known remaining work
docs/triage.md's "Multi-tracker support" heading needs reverting to "Multi-forge support" (thetracker/forgeharness-split idea was rejected upstream — see docs!: add ADR 0088 for CEL-guarded overlays in the harness schema fullsend#6237 discussion).LOCAL.md's Jira walkthrough still referencesFULLSEND_TRACKERinstead ofFULLSEND_FORGE/--forge jira.Test plan
make script-build check-bundle script-testpasses locallyJIRA_TOKENsandbox-exposure TODO abovefullsend run triage --forge jiraagainst a real Jira Cloud issueAssisted-by: Claude Opus 4.6 noreply@anthropic.com