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

cquery: Factor RepositoryName into fetching ignored packages #22142

Closed

Conversation

illicitonion
Copy link
Contributor

Previously this code was assuming that all cquery target patterns should
use the root repository's .bazelignore contents which was incorrect.

Because the way this manifested itself was that when cquery drives
populating the graph and when it queries it, it would use different
keys, this led to misleading messages about packages not being in scope.

@github-actions github-actions bot added team-Performance Issues for Performance teams team-Configurability Issues for Configurability team awaiting-review PR is awaiting review from an assigned reviewer labels Apr 26, 2024
Previously this code was assuming that all cquery target patterns should
use the root repository's .bazelignore contents which was incorrect.

Because the way this manifested itself was that when cquery drives
populating the graph and when it queries it, it would use different
keys, this led to misleading messages about packages not being in scope.
@illicitonion
Copy link
Contributor Author

cc @gregestren - this PR is ~trivial if you have a moment :)

@katre
Copy link
Member

katre commented Apr 26, 2024

Nice catch. I was curious what the actual error is, so I ran just the new test in Bazel at HEAD:

ERROR: Error doing post analysis query: Evaluation failed: Unable to load package '[/tmp/output_user_root/3394db9ced115d0552ae2a43f5662f9f/external/repo]/[]' because package is not in scope. Check that all target patterns in query expression are within the --universe_scope of this query.

Definitely a fix we should merge..

@katre katre added type: bug awaiting-PR-merge PR has been approved by a reviewer and is ready to be merge internally and removed team-Performance Issues for Performance teams awaiting-review PR is awaiting review from an assigned reviewer labels Apr 26, 2024
@illicitonion illicitonion deleted the cquery-external-bazelignore branch April 29, 2024 09:09
@sgowroji sgowroji removed the awaiting-PR-merge PR has been approved by a reviewer and is ready to be merge internally label Apr 30, 2024
Kila2 pushed a commit to Kila2/bazel that referenced this pull request May 13, 2024
Previously this code was assuming that all cquery target patterns should
use the root repository's .bazelignore contents which was incorrect.

Because the way this manifested itself was that when cquery drives
populating the graph and when it queries it, it would use different
keys, this led to misleading messages about packages not being in scope.

Closes bazelbuild#22142.

PiperOrigin-RevId: 628477138
Change-Id: I84e3381848b843ca9813acdd0762a3b3e4711a90
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team-Configurability Issues for Configurability team type: bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants