Skip to content

feat(app): add /restart session command#18496

Closed
anduimagui wants to merge 4 commits intoanomalyco:devfrom
anduimagui:app/session-clear-command
Closed

feat(app): add /restart session command#18496
anduimagui wants to merge 4 commits intoanomalyco:devfrom
anduimagui:app/session-clear-command

Conversation

@anduimagui
Copy link
Contributor

@anduimagui anduimagui commented Mar 21, 2026

Issue for this PR

Closes #18495

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Adds a /restart session command that opens a fresh session draft seeded with the first user message from the current session, so it is clear that this action restarts from the user's initial query instead of creating a generic blank session.

It also keeps /fork as the branch-from-any-message flow, while the shared fork utility continues to handle the dialog-based fork path separately.

How did you verify your code works?

I added focused coverage for the fork helper and a restart e2e regression that checks the new draft route and restored prompt content.

I also ran:

  • bun test --preload ./happydom.ts ./src/pages/session/fork.test.ts
  • bun typecheck

I attempted bun test:e2e:local -- e2e/session/session-restart.spec.ts, but local e2e is currently blocked by an unrelated preview-version issue in this workspace.

Screenshots / recordings

Not included.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@github-actions github-actions bot added contributor needs:compliance This means the issue will auto-close after 2 hours. labels Mar 21, 2026
@anduimagui anduimagui changed the title feat(app): add /clear session command feat(app): add /restart session command Mar 21, 2026
@github-actions github-actions bot removed the needs:compliance This means the issue will auto-close after 2 hours. label Mar 21, 2026
@github-actions
Copy link
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

@github-actions github-actions bot added needs:compliance This means the issue will auto-close after 2 hours. and removed needs:compliance This means the issue will auto-close after 2 hours. labels Mar 21, 2026
@github-actions
Copy link
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

@anduimagui
Copy link
Contributor Author

Closing this in favor of #18499, which uses the clean branch and contains the same work without the extra branch-history noise.

@anduimagui anduimagui closed this Mar 21, 2026
@anduimagui
Copy link
Contributor Author

Closing this in favor of #18499, which uses the clean 'app-session-restart-command' branch and contains the same '/restart' work without the extra branch-history noise.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]: add /restart session command

1 participant