Skip to content

fix: durable project disable (INT-2799) + commit preserved partial work (INT-2729)#301

Merged
unohee merged 2 commits into
mainfrom
fix/int-2799-durable-disable
Jul 16, 2026
Merged

fix: durable project disable (INT-2799) + commit preserved partial work (INT-2729)#301
unohee merged 2 commits into
mainfrom
fix/int-2799-durable-disable

Conversation

@unohee

@unohee unohee commented Jul 16, 2026

Copy link
Copy Markdown
Owner

Two independent daemon-durability fixes surfaced from Todo triage.

INT-2799 — dashboard project disable doesn't survive a restart

/api/projects/toggle disable only cleared the in-memory enabled set + the project-selection file. On restart applyReposConfig re-enables from repos.json and config.yaml re-allows via allowedProjects, so a config-defined project (e.g. vega-agent) revived and resumed work. Fix: toggle-disable now adds the path to removedConfigPaths — the hard R6 denylist reconcile filters on — symmetric with enable (which already clears it).

  • src/support/web.ts: add to denylist on soft-disable
  • src/support/web.reposReload.test.ts: regression — a denylisted config project stays out of enabled + allowedProjects across a reconcile

INT-2729 — preserved partial work was never committed

preserveWorktree kept a failed session's worktree for resume but left the work uncommitted, so a manual dir cleanup lost it silently (STO-1351: a 700+ line finished service preserved 7 days with zero commits, nearly lost). Fix: best-effort WIP commit to the swarm branch before the marker is written (so git add -A never stages the internal .openswarm-preserved control file). removeWorktree keeps the branch, so the commit survives dir removal. Never throws (INT-2521 ENOSPC discipline). The Linear failure comment half of the ticket is already handled by syncFailureState, so no duplicate comment was added.

  • src/support/worktreeManager.ts: commit-before-marker in preserveWorktree
  • src/support/worktreeManager.test.ts: work recoverable from branch after dir removal; marker absent from the committed tree

Validation

  • npx tsc --noEmit — clean
  • 124 tests across the 3 affected suites pass (web.reposReload, worktreeManager, runnerExecution.coverage)
  • openswarm review: first pass flagged the marker-in-commit side effect → fixed (commit reordered before marker) + asserted in test; re-review hit the harness 15-turn agentic-loop timeout without a concrete follow-up finding

🤖 Generated with Claude Code

unohee added 2 commits July 16, 2026 11:18
…t (INT-2799)

Dashboard toggle-disable only cleared the in-memory enabled set + project-
selection file; on daemon restart reconcileRepos re-enables from repos.json
and config.yaml re-allows via allowedProjects, so a config-defined project
(e.g. vega-agent) revived and resumed work. Add the path to removedConfigPaths
— the hard R6 denylist applyReposConfig filters on — so a soft-disable survives
restarts. Symmetric with enable, which already clears the denylist.
…g marker (INT-2729)

preserveWorktree kept a failed session's worktree dir for resume but left the
partial work UNCOMMITTED, so a manual cleanup of the dir lost it silently — even
a substantial finished implementation (STO-1351: 700+ line service preserved 7
days, zero commits, nearly lost). Capture the dirty work as a best-effort WIP
commit on the swarm branch so it survives dir removal as a recoverable git ref.
Commit runs BEFORE the marker is written so git add -A never stages the internal
.openswarm-preserved control file into user history. Never throws (INT-2521
ENOSPC discipline). Linear failure notification is already handled by
syncFailureState, so no duplicate comment is added.
@unohee
unohee merged commit a706eae into main Jul 16, 2026
5 checks passed
@unohee
unohee deleted the fix/int-2799-durable-disable branch July 16, 2026 02:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant