melodic-thailand-9922711/02/2021, 1:49 PM
, with 3 files •
and some other binary imports
directly. When packaging the binary it fails to package both
I’m using pants 2.7.1 Is there a way to help the inference? or should I just specify files manually?
enough-analyst-5443411/02/2021, 1:53 PM
melodic-thailand-9922711/02/2021, 1:55 PM
happy-kitchen-8948211/02/2021, 2:35 PM
deps on by default?
hundreds-father-40411/02/2021, 3:12 PM
in a BUILD file (called
before Pants 2.8), that generates one
target per file in the
field. Those generated targets inherit all the metadata you set in the
. So, if you have this:
python_sources( dependencies=["dep1", "dep2", "dep3"], )
target generated for
will have all three of those deps, even though it might not actually use them. Then, when you combine with
inference, this means that everything located recursively under that
will transitively depend on those 3 deps. You end up depending on way more than you actually wanted -- That is much less of a concern in a world where you use dependency inference, and particularly because we now have the
mechanism https://www.pantsbuild.org/v2.8/docs/reference-python_sources#codeoverridescode It's now feasible for us to switch the default. Although we have to do that with a deprecation. Thoughts?