Skip to content

Fix freebuff stale session takeover#605

Merged
jahooma merged 1 commit intomainfrom
jahooma/freebuff-stale-lock
May 6, 2026
Merged

Fix freebuff stale session takeover#605
jahooma merged 1 commit intomainfrom
jahooma/freebuff-stale-lock

Conversation

@brandonkachen
Copy link
Copy Markdown
Collaborator

Summary

Fixes freebuff restarts after Ctrl+C by releasing the free session slot from the chat exit path and auto-taking-over only when the prior local owner process is gone. Adds a small local owner marker keyed by server instance id and PID so genuinely concurrent local sessions still see the existing takeover prompt. Includes focused tests for the owner marker decision path.

Validation

  • bun run --cwd cli test ./src/utils/__tests__/freebuff-instance-owner.test.ts
  • bun run --cwd cli test ./src/utils/__tests__/keyboard-actions.test.ts
  • bun run --cwd cli typecheck

@jahooma jahooma merged commit e3a4e71 into main May 6, 2026
35 checks passed
@jahooma jahooma deleted the jahooma/freebuff-stale-lock branch May 6, 2026 18:59
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.

2 participants