Make it an error to not handle duplicates explicitly#15759
Merged
Conversation
Previous Gradle releases used a default 'include' strategy for copy specs: if a duplicate was found, then Gradle would silently include the duplicate, potentially overwriting the previous entry. In Gradle 5, we introduced a warning whenever duplicates are found and that no explicit deduplication strategy is set. With Gradle 7, this now becomes an error. Closes #15594
73cf6f8 to
a1de6d0
Compare
Contributor
Author
|
@bot-gradle test this |
Collaborator
|
OK, I've already cancelled the old build and triggered a new ReadyForMerge build for you. |
Contributor
Author
|
@bot-gradle test this |
Collaborator
|
OK, I've already triggered ReadyForMerge build for you. |
wolfs
reviewed
Jan 14, 2021
Member
wolfs
left a comment
There was a problem hiding this comment.
The change looks good overall. I left some comments.
subprojects/core/src/integTest/groovy/org/gradle/api/tasks/CopyTaskIntegrationSpec.groovy
Show resolved
Hide resolved
subprojects/core/src/integTest/groovy/org/gradle/api/tasks/CopyTaskIntegrationSpec.groovy
Outdated
Show resolved
Hide resolved
subprojects/core/src/main/java/org/gradle/api/internal/file/DefaultFileOperations.java
Outdated
Show resolved
Hide resolved
subprojects/core/src/main/java/org/gradle/api/internal/file/copy/CopyActionExecuter.java
Outdated
Show resolved
Hide resolved
subprojects/core/src/main/java/org/gradle/api/internal/file/copy/FileCopier.java
Outdated
Show resolved
Hide resolved
1 task
This was referenced Apr 13, 2021
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previous Gradle releases used a default 'include' strategy for
copy specs: if a duplicate was found, then Gradle would silently
include the duplicate, potentially overwriting the previous entry.
In Gradle 5, we introduced a warning whenever duplicates are found
and that no explicit deduplication strategy is set. With Gradle 7,
this now becomes an error.
Closes #15594