Skip to content

fix(app): resume sessions in desktop app#19407

Closed
anduimagui wants to merge 15 commits into
anomalyco:devfrom
anduimagui:andrew/desktop-session-resume
Closed

fix(app): resume sessions in desktop app#19407
anduimagui wants to merge 15 commits into
anomalyco:devfrom
anduimagui:andrew/desktop-session-resume

Conversation

@anduimagui
Copy link
Copy Markdown

Issue for this PR

Closes #19406

Type of change

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

What does this PR do?

This wires the desktop app's session page through the existing resume lifecycle so reopening an existing session triggers the same resume hook path that already exists on the server and in the TUI.

The app now syncs first, resumes once per reopened session, and skips that initial resume call for brand-new sessions and fresh forks so only true reopen flows trigger resume. I also added a small shared helper plus focused tests around the one-shot skip and retry behavior.

This depends on #18007 because that PR adds the backend/session lifecycle support that this app-side wiring calls.

How did you verify your code works?

I added focused unit coverage for the new app-side resume helper.

In this checkout, running the app-specific verification commands is still blocked by existing environment issues:

  • bun test src/pages/session/session-resume.test.ts currently fails because packages/app/happydom.ts imports missing @happy-dom/global-registrator
  • bun typecheck in packages/app is blocked by existing workspace dependency resolution issues in this checkout

Screenshots / recordings

N/A

Checklist

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

@github-actions
Copy link
Copy Markdown
Contributor

The following comment was made by an LLM, it may be inaccurate:

Based on my search, I found one related PR:

Related PR:

No duplicate PRs found.

@rekram1-node
Copy link
Copy Markdown
Collaborator

Automated PR Cleanup

Thank you for contributing to opencode.

Due to the high volume of PRs from users and AI agents, we periodically close older PRs using automated criteria so maintainers can focus review time on the most active and community-supported contributions.

This PR was closed because it matched the following cleanup criteria:

  • The PR was created more than 1 month ago
  • The PR had fewer than 2 positive reactions
  • Positive reactions are counted as thumbs-up, heart, celebration, or rocket reactions on the PR

PRs created within the last month are not affected by this cleanup.

If you believe this PR was closed incorrectly, or if you are still actively working on it, please leave a comment explaining why it should be reopened. A maintainer can review and reopen it if appropriate.

Thanks again for taking the time to contribute.

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.

Desktop app should resume existing sessions when reopened

3 participants