feat: add heartbeat_tick tool for automated task pickup (#13) (#14)

Adds heartbeat_tick tool that automates task pickup across all projects:

- Runs session health checks (zombie cleanup) before pickups
- Loops over all registered projects
- Picks up tasks by priority (To Improve > To Test > To Do)
- Supports two work modes:
  - parallel: each project can have DEV+QA running independently
  - sequential: only 1 DEV + 1 QA globally (can be different projects)
- Respects per-project maxDevWorkers/maxQaWorkers settings
- Supports dryRun mode and maxPickups limit
- Context guard: only works from DM/cron, blocks project groups

Also adds:
- workMode config option (parallel | sequential)
- maxDevWorkers/maxQaWorkers fields to Project type
This commit is contained in:
Lauren ten Hoor
2026-02-09 23:49:13 +08:00
committed by GitHub
parent 4f4952f978
commit 9afa318697
3 changed files with 515 additions and 1 deletions

View File

@@ -23,6 +23,8 @@ export type Project = {
baseBranch: string;
deployBranch: string;
autoChain: boolean;
maxDevWorkers?: number;
maxQaWorkers?: number;
dev: WorkerState;
qa: WorkerState;
};