Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR introduces support for Rust as an experimental analysis language.
- Updated query wizard tests to include "rust"
- Extended query history mappers and DTOs to support a new Rust language case
- Modified language selection data and common language definitions to incorporate Rust
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| extensions/ql-vscode/test/vscode-tests/cli-integration/local-queries/skeleton-query-wizard.test.ts | Added "rust" to the list of languages for testing the query wizard |
| extensions/ql-vscode/src/query-history/store/query-history-language-dto-mapper.ts | Mapped QueryLanguageDto.Rust to QueryLanguage.Rust |
| extensions/ql-vscode/src/query-history/store/query-history-language-domain-mapper.ts | Mapped QueryLanguage.Rust to QueryLanguageDto.Rust |
| extensions/ql-vscode/src/query-history/store/query-history-dto.ts | Added a new enum value for Rust |
| extensions/ql-vscode/src/language-selection-panel/language-selection-data-provider.ts | Included Rust in the language selection options |
| extensions/ql-vscode/src/common/query-language.ts | Updated enum, display name mapping, and pack associations to support Rust |
Tip: If you use Visual Studio Code, you can request a review from Copilot before you push from the "Source Control" tab. Learn more
koesie10
left a comment
There was a problem hiding this comment.
Thanks, this makes sense to me.
The only thing I can find that might be missing is this constant. While we may not have a good repo yet, we also don't really handle it being empty. This is probably fine for now since the CLI server will not return Rust as a supported language, but if we do have a repo that we can add here, that would be nice. Perhaps just adding github/stack-graphs for now would be fine?
@koesie10 Thanks for spotting that. What should be the qualities of a repo to be added to that mapping? Long term, I'd probably go for https://github.com/denoland/deno, it's a top-rated rust repository and we know we extract it pretty well already. Should I go for that already, or should I stick to GitHub owned repositories while we only staff shipped? |
I think generally we go for somewhat well-known repositories that also aren't too large. I think it could make sense to go for |
Ok, |

This allows to interact with qlpacks that use rust as a language, which is currently experimental. The CLI will currently advertise Rust language support only if
CODEQL_ENABLE_EXPERIMENTAL_FEATURESis set to true. By looking at past changes for Swift, I understand we don't need to do anything special about that in the extension, as the extension will just query the CLI for supported languages.