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

invalidate dependency targets if in combined mode #7455

Conversation

Projects
None yet
2 participants
@thoward
Copy link
Contributor

commented Mar 29, 2019

Problem

The doc.scaladoc task (and likely also the doc.javadoc task), when used with --combined is skipping dependencies in the graph during the 'invalidation' stage, because it is not passing invalidate_dependents in the docable predicate that is part of the base class JvmDocGen.

See issue: #7434

Solution

In the relevant spot in JvmDocGen class, this change passes the invalidate_dependents parameter to self.invalidate() with attribute self.combined for the value which is True for combined doc builds and False otherwise.

Result

This causes the invalidation logic to behave as expected, specifically, invalidating the dependencies within the entire graph for a combined doc build. I tested this locally to ensure the correct behavior, and ran all relevant unit tests.

@stuhood stuhood self-assigned this Mar 29, 2019

@stuhood
Copy link
Member

left a comment

Thanks Troy! One other tweak I think.

@thoward

This comment has been minimized.

Copy link
Contributor Author

commented Apr 3, 2019

NOTE: The CI failure listed below seems unrelated to this changeset. The related test within Travis is failing before it even tests the code when attempting to bootstrap Pants. See log here: https://travis-ci.org/pantsbuild/pants/jobs/515087027

@stuhood

This comment has been minimized.

Copy link
Member

commented Apr 3, 2019

@thoward : Agreed, will restart the run.

jvmdoc tasks (combined): only regenerate docs if there are invalidate…
…d targets, move page open logic outside of conditional build
@stuhood

stuhood approved these changes Apr 5, 2019

Copy link
Member

left a comment

Great, thank you sir! You probably hit some CI flakes. Have bounced them and will merge on green.

@stuhood stuhood merged commit 454ce5e into pantsbuild:master Apr 5, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@thoward thoward deleted the thoward:thoward/pants/bug/scaladoc_combined_filters_out_docable_dependencies branch Apr 26, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.