Skip to content

[FEATURE]: Add a manual reload action for the current project instance in webui #29266

@c-w-xiaohei

Description

@c-w-xiaohei

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

OpenCode can keep a long-lived server process with cached instances for different projects/worktrees. When working on project-scoped configuration or extension files, such as agents, skills, plugins, or MCP-related setup, the current instance can keep using the old bootstrapped state.

The current workaround is usually to restart the server/app, or to dispose the instance and let a later request recreate it. Restarting is too broad because it affects unrelated projects/worktrees. Disposing is also not a great user-facing reload action because it only tears down the old instance; it does not tell the caller whether a replacement instance can boot successfully.

I would like a small manual reload action for the currently routed project/worktree instance.

A first version could add:

  • POST /instance/reload, scoped by the existing workspace/directory routing.
  • A typed API error when the replacement instance fails to boot.
  • A WebUI Reload instance action that shows success/failure feedback.

This is intentionally smaller than full hot reload. It does not need to watch files automatically, reload every workspace, reconcile MCP clients incrementally, or guarantee that active runs inside the same instance continue uninterrupted.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions