https://pantsbuild.org/ logo
#general
Title
# general
w

wide-wall-52265

01/14/2020, 6:19 PM
Is there any good guide on BUILD file optimization? a recent change i made has been causing a lot of
duplicate file
warnings
a

aloof-angle-91616

01/14/2020, 6:20 PM
sorry — what is the error message exactly?
w

wide-wall-52265

01/14/2020, 6:21 PM
At the end of a java compilation i get a warning that says
Duplicate file: com/${COMPANY_NAME}/${PACKAGE_NAME}/${CLASSNAME}.class
. I scrubbed out the exact path, but its like that
a

aloof-angle-91616

01/14/2020, 6:21 PM
oh yes
that’s not with the BUILD file iirc
and it’s our fault i think
could i ask you quickly make an issue if/when you have time today? i think this is fixable and i think we either shouldn’t be creating those warnings or we need to fix what pants is doing that is being warned about
others have described this issue before and i’ve seen it and just haven’t fixed it yet
w

wide-wall-52265

01/14/2020, 6:23 PM
Can do! of note, the classes In that module are globbed together. I would prefer for them to be modular and get rid of all globs, but then i get a cyclic dependency issue.
a

aloof-angle-91616

01/14/2020, 6:24 PM
oh!! i’d love to look into that too
w

wide-wall-52265

01/14/2020, 6:25 PM
That ones been driving me nuts haha
a

aloof-angle-91616

01/14/2020, 6:25 PM
there’s a specific tool we’re developing at twitter to compile scala code in parallel and it may make processing cyclic deps better which would be an extremely cool result that i’d love to give a talk about if we can solve it (but haven’t been working on that at work lately)
for the dependency issue, feel free to post something here or as an issue!
3 Views