rokucommunity / rokucommunity/brighterscript
Language Server: Do not walk past workspaceFolders when searching for bsconfig.json
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 208
- Forks
- 68
- Avg merge
- 8h 39m
- Merged PRs (30d)
- 39
Description
Problem
When running BrighterScript in language server mode, such as within VSCode, the workspace context should limit which bsconfig.json files are detected. Currently, if a user opens a subfolder (e.g., C:/projects/alpha/build/) in a separate VSCode window, the language server incorrectly walks upwards in the file tree and discovers the parent C:/projects/alpha/bsconfig.json. This is not desired; we only want to use configuration files from within a user's active workspaceFolder context in the editor.
For CLI usage (such as building from nested folders), walking upward to find parent bsconfig.json is correct and expected. But in editor/language-server scenarios, we should confine the search to the current workspaceFolder only.
Expected Behavior
- In language server mode, BrighterScript should not search past the active workspaceFolder boundary when locating
bsconfig.jsonfiles. - In CLI mode, upward search for parent
bsconfig.jsonfiles should continue as usual.
Additional Context
This distinction prevents cases where an unintended parent configuration is loaded in VSCode, which is confusing to users working in subfolders or opening multiple editor windows for parts of larger repositories.
Summary
Prevent BrighterScript language server from walking past workspaceFolders when searching for bsconfig.json.
Only upward search for parent configs in CLI mode.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in the language-server configuration discovery path and trace how workspaceFolders and bsconfig.json parent searches are handled. Verify the behavior in an editor workspace opened at a subfolder, then confirm CLI searches still walk upward; done means editor searches stop at the active workspaceFolder while CLI behavior is unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100