feat(issues): link a finding's issue to the finding itself (#947) #948

Merged
sharang merged 1 commits from feat/947-finding-link into main 2026-11-10 13:48:44 +00:00
Owner

What changed

  • The "Open in Prüfwerk / In Prüfwerk öffnen" link in a new finding issue (managed repositories) now opens the finding's own dashboard page, {DASHBOARD_PUBLIC_URL}/findings/{finding_id}, where its status can be set, instead of the target's finding list (/findings?target=…). A group (#464) has its own finding id and links to its own page.
  • finding_link (compliance-agent/src/pipeline/issue_creation.rs) takes the finding id. The link is still https-only, and it is left out when a finding has no id. In practice new findings get their id from write_back, and catch-up findings come from the database, so both have one.
  • IssueSink::open works out the finding id once and uses it for the link and for the stored TrackerIssue.

Not changed:

  • The "new findings" notification (agent.rs) still links to the target's list, because it is about several findings.
  • CVE issues (cve_issues.rs) still link to the target page. That page has no anchor for a CVE section to link to (compliance-dashboard/src/pages/target.rs), and this PR adds no UI.

Existing issues

Existing issues keep their old link. The issue sync (issue_sync.rs, issue_catchup.rs) changes an issue's state and labels and adds comments, but it never edits an issue body, and the Gitea tracker has no call to do that. Updating old links would mean a new body PATCH for every issue on every sync, so it is left out. The old link still works: it opens the target's finding list.

How tested

  • cargo fmt --all --check
  • RUSTFLAGS="-D warnings" cargo clippy -p compliance-agent --all-targets -j8 -- -D warnings
  • cargo test -p compliance-agent --lib -j8 issue: 33 passed. links_the_finding_page_of_an_https_dashboard replaces the test of the old URL and also checks the https-only rule and the case without an id.

Closes #947

🤖 Generated with Claude Code

## What changed - The "Open in Prüfwerk / In Prüfwerk öffnen" link in a new finding issue (managed repositories) now opens the finding's own dashboard page, `{DASHBOARD_PUBLIC_URL}/findings/{finding_id}`, where its status can be set, instead of the target's finding list (`/findings?target=…`). A group (#464) has its own finding id and links to its own page. - `finding_link` (`compliance-agent/src/pipeline/issue_creation.rs`) takes the finding id. The link is still https-only, and it is left out when a finding has no id. In practice new findings get their id from `write_back`, and catch-up findings come from the database, so both have one. - `IssueSink::open` works out the finding id once and uses it for the link and for the stored `TrackerIssue`. Not changed: - The "new findings" notification (`agent.rs`) still links to the target's list, because it is about several findings. - CVE issues (`cve_issues.rs`) still link to the target page. That page has no anchor for a CVE section to link to (`compliance-dashboard/src/pages/target.rs`), and this PR adds no UI. ## Existing issues Existing issues keep their old link. The issue sync (`issue_sync.rs`, `issue_catchup.rs`) changes an issue's state and labels and adds comments, but it never edits an issue body, and the Gitea tracker has no call to do that. Updating old links would mean a new body PATCH for every issue on every sync, so it is left out. The old link still works: it opens the target's finding list. ## How tested - `cargo fmt --all --check` - `RUSTFLAGS="-D warnings" cargo clippy -p compliance-agent --all-targets -j8 -- -D warnings` - `cargo test -p compliance-agent --lib -j8 issue`: 33 passed. `links_the_finding_page_of_an_https_dashboard` replaces the test of the old URL and also checks the https-only rule and the case without an id. Closes #947 🤖 Generated with [Claude Code](https://claude.com/claude-code)
sharang added 1 commit 2026-11-10 10:26:26 +00:00
feat(issues): link a finding's issue to the finding itself (#947)
CI / Check (push) Skipped
CI / Detect Changes (pull_request) Skipped
CI / Agent integration (pull_request) Successful in 4m24s
CI / Deploy Agent (pull_request) Skipped
CI / Deploy Dashboard (pull_request) Skipped
CI / Deploy Docs (pull_request) Skipped
CI / Deploy MCP (pull_request) Skipped
CI / Check (pull_request) Successful in 18m16s
f32e0d1610
The "Open in Prüfwerk" link in a finding's issue went to the target's
whole finding list. It now opens the finding's own page
(/findings/{id}), where its status is set; a group (#464) links to its
own page. The link stays https-only and is left out for a finding
without an id. CVE issues and the new-findings notification keep their
links.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
sharang merged commit b9acabb6ba into main 2026-11-10 13:48:44 +00:00
Sign in to join this conversation.