Skip to content

Feat/clear command#108

Merged
Qsnh merged 4 commits intofeat/worker-engine-selectionfrom
feat/clear-command
Apr 19, 2026
Merged

Feat/clear command#108
Qsnh merged 4 commits intofeat/worker-engine-selectionfrom
feat/clear-command

Conversation

@Qsnh
Copy link
Copy Markdown
Contributor

@Qsnh Qsnh commented Apr 19, 2026

No description provided.

Qsnh and others added 4 commits April 18, 2026 21:31
Implements two variants scoped to the current session:
- /clear: clears all session contexts after two-step confirmation (stops running tasks first)
- /clear {workerName}: clears a specific worker's active-engine context after confirmation

Confirmation state is held in memory with a 30-second expiry; the second
command must match the first exactly (case-sensitive). Worker name lookup
is case-insensitive and errors on duplicate names.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…leak

- Extract sendReply package-level helper; both EngineCommandHandler and
  ClearCommandHandler delegate to it instead of duplicating the logic
- GetByName now delegates to ListByName, eliminating the duplicate SQL
- Add sweepExpired goroutine to ClearCommandHandler so unconfirmed
  /clear entries don't accumulate in memory indefinitely

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… handler

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Qsnh Qsnh merged commit 4b14f06 into feat/worker-engine-selection Apr 19, 2026
@Qsnh Qsnh deleted the feat/clear-command branch April 19, 2026 05:08
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