agent-orchestrator/backend/internal/httpd/controllers
Khushi Diwan 7d0ca02440
fix(project): resolve default branch from origin/HEAD, not checked-out branch (#289)
* fix(project): resolve default branch from origin/HEAD, not checked-out branch

Detecting the project default via `symbolic-ref --short HEAD` captured
whatever branch the repo happened to be on at add time. Adding a project
while on a feature branch (e.g. fix/pr-attachment) persisted that branch
as the default, so every session worktree based off it instead of main.

Prefer the remote default (origin/HEAD), falling back to the checked-out
branch only when no remote default is set. This still records a non-main
default like master correctly, while ignoring the active feature branch.

* test: cover branch-not-fetched API error
2026-06-19 19:50:19 +05:30
..
dto.go feat(session): support multiple PRs per session (#230) 2026-06-17 17:31:28 +05:30
notifications.go feat: add notifications v1 (#181) 2026-06-14 20:02:32 +05:30
notifications_test.go feat: add notifications v1 (#181) 2026-06-14 20:02:32 +05:30
projects.go feat(config): persist per-project agent config and resolve it at spawn (#154) 2026-06-08 21:35:29 +05:30
projects_test.go fix(project): detect the repo's default branch on add (#209) 2026-06-15 14:51:07 +05:30
prs.go feat(api): PR action routes — merge + resolve-comments (#88) 2026-06-03 04:43:50 +05:30
prs_test.go refactor(backend): LLD maintainability fixes in controllers/service layers (#95) (#96) 2026-06-03 18:09:02 +05:30
reviews.go feat(review): configurable AO code review backend (V1) (#192) (#197) 2026-06-15 01:17:17 +05:30
sessions.go feat(session): support multiple PRs per session (#230) 2026-06-17 17:31:28 +05:30
sessions_activity_test.go feat: add notifications v1 (#181) 2026-06-14 20:02:32 +05:30
sessions_test.go fix(project): resolve default branch from origin/HEAD, not checked-out branch (#289) 2026-06-19 19:50:19 +05:30