feat(config): hot-reload config on file changes#22010
feat(config): hot-reload config on file changes#22010tobias-weiss-ai-xr wants to merge 1 commit intoanomalyco:devfrom
Conversation
Subscribe to file watcher events via GlobalBus and trigger Instance.disposeAll() when opencode.json/opencode.jsonc/config.json files change. Uses a 500ms debounce to avoid rapid reloads. This causes the provider system and all per-instance state to be rebuilt with fresh config on the next access.
|
This PR doesn't fully meet our contributing guidelines and PR template. What needs to be fixed:
Please edit this PR description to address the above within 2 hours, or it will be automatically closed. If you believe this was flagged incorrectly, please let a maintainer know. |
|
The following comment was made by an LLM, it may be inaccurate: Based on the search results, I found several potentially related PRs: Potential Duplicates/Related PRs:
These PRs share similar concepts (file watching, cache invalidation, reload/hot-reload patterns) but don't appear to be exact duplicates of the config hot-reload feature. PR #22010 appears to be the unique implementation for config-specific hot-reload. |
|
This pull request has been automatically closed because it was not updated to meet our contributing guidelines within the 2-hour window. Feel free to open a new pull request that follows our guidelines. |
Summary
Config.invalidate()to force fresh config load on next accessTest plan