Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow override of query with cquery #392

Open
ayashjorden opened this issue May 3, 2024 · 3 comments
Open

Allow override of query with cquery #392

ayashjorden opened this issue May 3, 2024 · 3 comments

Comments

@ayashjorden
Copy link

Hello,
I'm working on a project where bazel is wraped with a toolchain. configuring vscode to use the wrapper was easy, so thank you for enabling that.

When I trigger a Bazel: build target, the extension makes the call to our bazel wrapper with a query sub-command. query is disavled/prohibited in our Bazel workspace.

Is there a way to override that and use cquery instead?

Thank you

@vogelsgesang
Copy link
Collaborator

Currently, no such option exists.

I am not opposed to adding such an option, but I am not sure about the tradeoffs here. Based on which tradeoffs was "query" disabled in your Bazel workspace?

For the time being, you could probably work around it by writing another wrapper script that replaces "query" by "cquery" before forwarding the call to your underlying bazel wrapper.

@ayashjorden
Copy link
Author

Currently, no such option exists.

I am not opposed to adding such an option, but I am not sure about the tradeoffs here. Based on which tradeoffs was "query" disabled in your Bazel workspace?

For the time being, you could probably work around it by writing another wrapper script that replaces "query" by "cquery" before forwarding the call to your underlying bazel wrapper.

Thanks @vogelsgesang , that's what I ended up doing.
I am not sure as I'm new to the team/org and still looking around.

Currently hitting issues with Error while parsing 'kind(.* rule, ...)': syntax error at 'rule , ...', but that's probably on our side of the call.

Appreciate the help!

As I'm not (yet) a Bazel expert, would it be still valid to add support for cquery as part of the plugin?

@vogelsgesang
Copy link
Collaborator

As I'm not (yet) a Bazel expert, would it be still valid to add support for cquery as part of the plugin?

I am also not a Bazel expert. Also just a user... maybe @jfirebaugh or @cameron-martin have more in-depth thoughts on the tradeoffs between query vs cquery

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants