You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a dependency is added within a pre_build function of the current rule, then please doesn't wait for the new dependency to be built before proceeding.
However, running please a second time, with the dependency now cached, works fine.
This is a similar issue as #3168, since please misses some blocking functionality within the buildTarget function for pre and post build calls for cases where dependencies may change.
Ideally, adding new dependencies to the current rule should be permissible in pre_build, since there are cases where the sources are not fully known until build time.
Specifically, this is something I noticed when using please to generate code that is then compiled in a separate rule. In that case, the cc-rules for instance, will only use a single build step to compile a potentially large number of sources, running on a single thread. Instead, it should be possible to go through the sources in a pre_build rule, to generate rules according to the actual files input.
The text was updated successfully, but these errors were encountered:
I don't think this is intended to work at present. I thought we checked for this but I guess apparently not. Basically it runs the pre-build function at the point it's about to build a target - at that point it isn't expecting to back off and build something else. Conceptually it could be made to do that but I don't think that's extremely easy - e.g. the building target currently is taking up one of the build workers, it really needs to release that if it's going to wait for another thing to build, but I don't think there's a good way of handling that right now.
I see the point with the generated code situation - I've observed that before too, and it would be nice if this were possible.
If a dependency is added within a
pre_build
function of the current rule, then please doesn't wait for the new dependency to be built before proceeding.However, running please a second time, with the dependency now cached, works fine.
This is a similar issue as #3168, since please misses some blocking functionality within the buildTarget function for pre and post build calls for cases where dependencies may change.
Ideally, adding new dependencies to the current rule should be permissible in
pre_build
, since there are cases where the sources are not fully known until build time.Specifically, this is something I noticed when using please to generate code that is then compiled in a separate rule. In that case, the cc-rules for instance, will only use a single build step to compile a potentially large number of sources, running on a single thread. Instead, it should be possible to go through the sources in a
pre_build
rule, to generate rules according to the actual files input.The text was updated successfully, but these errors were encountered: