Watch
0
0
Fork
You've already forked hyperhive
0

swarm-ui, swarm-controller: the review try-out's repo and PR fields offer the repos and PRs to pick

Two read-only routes feed them: GET /api/pulls/repos lists the repos with an
open pull request, and GET /api/pulls?repo=owner/name lists a repo's open
pull requests, highest number first. The page offers the lists through the
browser's own suggestion list and keeps both fields free text, since a run
also works on a merged or closed PR.
This commit is contained in:
iris 2026-10-12 19:05:37 +02:00
commit 9a4059e130
10 changed files with 399 additions and 7 deletions

View file

@ -57,6 +57,7 @@ mod issue_report;
mod linked_accounts;
mod matrix_account;
mod otel_http_client;
mod pulls;
mod queue_identity;
mod read_policy;
mod review_classifier;
@ -768,6 +769,7 @@ fn socket_path() -> PathBuf {
(name = "forge", description = "forge site admins (`swarmctl forge make-admin`)"),
(name = "schedules", description = "scheduled prompts (`swarmctl schedule`)"),
(name = "review-classifier", description = "trying review classifications against a PR (swarm-ui's try-out page)"),
(name = "pulls", description = "open pull requests, for the try-out page's dropdowns"),
)
)]
struct ApiDoc;
@ -3333,6 +3335,8 @@ fn build_app(state: AppState) -> axum::Router {
.routes(routes!(issue_report::get_repos))
.routes(routes!(issue_report::get_issue_report_all))
.routes(routes!(issue_report::get_issue_report))
.routes(routes!(pulls::get_pull_repos))
.routes(routes!(pulls::get_pulls))
.routes(routes!(review_classifier::post_try_out))
.routes(routes!(review_classifier::get_try_out))
.routes(routes!(review_classifier::get_rules))