Skip to content

fix(service): reject reuse across config and data directories - #64677

Draft
xun082 wants to merge 1 commit into
anomalyco:devfrom
xun082:service-path-isolation
Draft

xun082 wants to merge 1 commit into
anomalyco:devfrom
xun082:service-path-isolation

Conversation

@xun082

@xun082 xun082 commented Nov 18, 2026

Copy link
Copy Markdown

Issue for this PR

Closes #64661

Type of change

  • Bug fix

What does this PR do?

Desktop and CLI could reuse a service from a different XDG environment when both shared a state directory. The service now registers its launch config and data directories. Desktop checks them during startup discovery and reconnect. A live owner with different directories, or a legacy registration without directory information, stays running and the client explains how to stop it from its original environment.

How did you verify your code works?

  • Reproduced the issue with real CLI services using shared state and separate config and data roots. The old client selected the foreign service, where the native plugin was missing and its GUI bundle returned 404. With this change, native startup refused the foreign owner. Once the owner was stopped, the native service loaded the plugin and served its GUI bundle with HTTP 200.
  • Ran the managed CLI lifecycle tests, the full Client suite, targeted Desktop tests, and bun run check.

Screenshots / recordings

N/A

Checklist

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

This branch has not been deployed

No deployments
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.

desktop: reuses a background service with a different config directory and loses user plugins

1 participant