gsxdsm
9a34862586
refactor: package code organization waves 3–5 (#2148)
## Summary
Waves 3–5 of package code organization (plan:
`docs/plans/2026-07-14-001-refactor-package-code-organization-plan.md`).
Behavior-preserving peels after #2139 and #2143.
### Wave 3 — Merger + heartbeat recovery
- **`merger-errors.ts`** — verification/abort error classes
- **`merger-owned-landed.ts`** — ownership classification +
`Fusion-Task-Id` trailer
- **`merger-conflict-resolution.ts`** — conflict classify/auto-resolve
- **`agent-heartbeat-error-recovery.ts`** — durable error-recovery
budget helpers
### Wave 4 — Self-healing + dashboard API
- **`self-healing-constants.ts`** — public timing/budget constants
- **`self-healing-branch.ts`** — `isBranchAheadOfBase`
- **`app/api/client.ts`** — `api` / `ApiRequestError` / `buildApiUrl` /
`proxyApi`
- **`app/api/health.ts`** — health, engine status, updates +
`withProjectId`
### Wave 5 — Types tracking + merger parse + task CRUD
- **`types/task-tracking.ts`** — PR/issue/GitHub/GitLab tracking
contracts
- **`merger-git-parse.ts`** — `parseFailingFilesFromOutput`,
`parsePorcelainZ`, `parseShortstatSummary`
- **`app/api/tasks.ts`** — task list/detail/create/update/move client
surface
- Line-count baselines ratcheted down for `merger.ts`, `types.ts`,
`legacy.ts`
Public import paths stay on parent modules / `legacy.ts` / package
barrels via re-exports.
## Test plan
- [x] core/engine/dashboard typecheck (including `tsconfig.app.json`)
- [x] eslint on touched modules
- [x] `parse-porcelain-z` + merger parseFailing/getBranchChanged tests
- [x] dashboard `api-tasks` + legacy-prinfo/pr-types (69)
- [ ] CI merge gate
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
- **New Features**
- Added dashboard API support for task listing/detail, archiving,
creation, review updates, duplicate detection, bulk model updates,
moving tasks, and overlap repair.
- Added health/engine status and refresh/start controls, plus update
checking.
- **Bug Fixes**
- Improved dashboard API handling for non-JSON/HTML responses with
clearer errors, better URL routing for remote nodes, and project-scoped
queries.
- Strengthened automated recovery for heartbeat error/model-unavailable
scenarios and safer merge-conflict classification/auto-resolution.
- **Tests**
- Updated merge-conflict resolution and lifecycle test mocks to match
the updated git command behavior.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-07-16 00:01:17 -07:00
..
2026-07-15 08:44:11 -07:00
2026-07-14 23:18:55 -07:00
2026-06-03 17:36:35 -07:00
2026-07-13 19:07:58 -07:00
2026-04-27 08:21:48 -07:00
2026-05-12 07:47:11 -07:00
2026-07-13 19:07:58 -07:00
2026-07-14 23:18:55 -07:00
2026-07-13 19:07:58 -07:00
2026-07-08 04:24:30 -07:00
2026-07-15 08:44:11 -07:00
2026-07-14 23:18:55 -07:00
2026-06-23 23:30:32 -07:00
2026-06-25 23:34:08 -07:00
2026-07-13 07:10:14 -07:00
2026-05-23 19:51:36 -07:00
2026-07-14 08:16:42 -07:00
2026-06-14 15:29:35 -07:00
2026-07-12 21:21:10 -07:00
2026-06-14 15:29:35 -07:00
2026-04-27 08:21:48 -07:00
2026-06-13 19:22:00 -07:00
2026-07-13 01:21:33 -07:00
2026-06-13 15:44:28 -07:00
2026-04-27 08:21:48 -07:00
2026-05-11 09:52:23 +02:00
2026-07-10 13:26:23 -07:00
2026-07-12 14:42:09 -07:00
2026-04-27 08:21:48 -07:00
2026-07-12 14:42:09 -07:00
2026-06-19 20:47:32 -07:00
2026-06-18 16:47:09 -07:00
2026-07-16 00:01:17 -07:00
2026-06-16 18:03:41 -07:00
2026-07-14 23:18:55 -07:00
2026-07-13 19:07:58 -07:00
2026-07-14 23:18:55 -07:00
2026-07-13 19:07:58 -07:00
2026-07-13 19:07:58 -07:00
2026-04-27 08:21:48 -07:00
2026-07-13 23:00:25 -07:00
2026-07-14 23:18:55 -07:00
2026-06-24 19:25:44 -07:00
2026-06-21 10:53:08 -07:00
2026-05-27 21:31:12 -07:00
2026-03-30 23:56:01 -07:00
2026-03-26 01:03:16 -04:00
2026-07-15 08:44:11 -07:00
2026-07-14 23:18:55 -07:00
2026-04-27 08:21:48 -07:00
2026-06-30 08:04:12 -07:00
2026-04-29 08:15:38 -07:00
2026-06-25 22:56:10 -07:00
2026-07-03 07:47:03 -07:00
2026-07-02 11:38:31 -07:00
2026-06-25 17:04:30 -07:00
2026-06-24 23:32:52 -07:00
2026-07-08 11:19:47 -07:00
2026-05-03 05:47:11 -07:00
2026-07-15 14:41:05 -07:00
2026-07-03 22:04:45 -07:00
2026-06-19 05:13:39 -07:00