-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
bazel query output order is wrong for rules with attr specifying aspects that depend on utility target #12320
Comments
Could you clarify further what you meant by "the output order is wrong" in the proto file generated by your example, and how that affects the calculation of your target hash? |
when We are using the approach discussed in here to calculate the targethash and detect changed targets internally, parsing query output from bottom to top, with the assumption that query output order will reflect the dependency chain |
I think you meant I've tried reproducing it with your example and while B is a
Running The flag |
It seems there might be an issue with Not sure if this is related to your issue though since the |
I have noticed something similar after upgrading to Bazel 3.7.0, maybe this is the issue @zhengwei143 mentions. In my case it's the ordering of 2 package groups with
^ I've used |
Yeah I meant |
Thank you for contributing to the Bazel repository! This issue has been marked as stale since it has not had any activity in the last 1+ years. It will be closed in the next 14 days unless any other activity occurs or one of the following labels is added: "not stale", "awaiting-bazeler". Please reach out to the triage team ( |
This issue has been automatically closed due to inactivity. If you're still interested in pursuing this, please reach out to the triage team ( |
Description of the problem:
We've been using
bazel query --output=proto --order_output=full
approach to calculate the targethash for our repo. This has been working relatively well until we introduced a custom rule (target instanceA
) that:attr.label(aspect=...))
)B
)This forms dependency from A to B, and by invoking
GetRuleInput
on A seems to confirm that, but the output order is wrong despite--order_output=full
is specified.Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
I've forked the bazel example repo and made some small changes to simplify the case.
bazel query --output=proto --order_output=full "deps(//aspect:example_rule)"
and check the output proto file to see the issueWhat operating system are you running Bazel on?
macos 10.15.6
What's the output of
bazel info release
?3.3.1
Have you found anything relevant by searching the web?
No
The text was updated successfully, but these errors were encountered: