Old "Lua" output channel remains active after restarting server
還沒有人認領這個 Issue。
- 主要語言
- TypeScript
- 星號
- 215
- 分支
- 62
- PR 合併指標
- 30 天內沒有已合併 PR
描述
### Which OS are you using?
MacOS
### Expected Behaviour
When restarting the language server, I expect the output channel to be either
- cleared and reused by the new server instance
- or deleted and a new one used to replace it
### Actual Behaviour
The old channel is never destroyed, leaving multiple channels with the same name which can be confusing if you're looking for new channel output.
### Reproduction steps
1. Open a Lua file
2. Run the `Lua: Restart Language Server` command (many times makes it more obvious)
3. Open the output channel selector dropdown (`Output: Show Output Channels...`)
### Additional Notes
I think this is probably pretty simple to fix, just by either `clear()`ing and reusing or `destroy()`ing the [OutputChannel](https://code.visualstudio.com/api/references/vscode-api#OutputChannel) used for logging.
### Log
[file_Users_ianchamberlain_Documents_Development_moon-rs-ls.log](https://github.com/user-attachments/files/19100943/file_Users_ianchamberlain_Documents_Development_moon-rs-ls.log)
貢獻指南
這個儲存庫沒有索引到貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
從 `Lua: Restart Language Server` 命令的 handler 開始,追蹤其 VS Code `OutputChannel` 的建立和保留方式。反覆執行重新啟動,然後確認 `Output: Show Output Channels...` 中只包含目前的 Lua channel,且新的 server 輸出會出現在其中。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- typescript, vscode
- 領域
- tooling
- Issue 類型
- 缺陷
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 活躍度
- 停滯
- 描述清晰度
- 基本清楚
- 新手友好度
- 45/100