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

Include internal dependency in extraHash computation #1290

Merged
merged 2 commits into from
Nov 29, 2023

Conversation

Friendseeker
Copy link
Member

@Friendseeker Friendseeker commented Nov 28, 2023

Issue

PR #1289 addressed under-compilation for traits with transitive external inheritance dependencies by propagating TraitPrivateMembersModified from parent trait to child traits.

However, when the hierarchy consists a mix of internal & external dependencies, TraitPrivateMembersModified would fail to propagate, resulting in under compilation.

For example, say c.C -> b.B -> a.A, (c.C extends c.B, c.B extends a.A), for which c.C and c.B, a.A are on different projects, then when a.A 's private member is changed, the propagation stops at c.B since computation of c.B's extraHash only takes account of a.A's external dependency, while a.A is part of c.B's internal dependency. Hence c.C never gets recompiled.

Fix

Include internal dependency in extraHash computation.

Copy link
Member

@eed3si9n eed3si9n left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@eed3si9n eed3si9n merged commit 50df19a into sbt:develop Nov 29, 2023
7 checks passed
@Friendseeker Friendseeker deleted the trait-transitive-mixed-dependency branch November 29, 2023 18:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants