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

Fix Detekt gradle task cache restoration issue (#2180) #2182

Merged
merged 1 commit into from
Dec 17, 2019

Conversation

plastiv
Copy link
Contributor

@plastiv plastiv commented Dec 16, 2019

Detekt gradle task is marked as @CacheableTask but it's input source files are
marked with PathSensitivity.ABSOLUTE annotation from source property defined in
parent SourceTask.

Having task inputs with absolute path sensitivity effectively disables cache reusability:
https://guides.gradle.org/using-build-cache/#relocatability

Closes #2180

@codecov-io
Copy link

codecov-io commented Dec 16, 2019

Codecov Report

Merging #2182 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #2182   +/-   ##
=========================================
  Coverage     80.59%   80.59%           
  Complexity     2028     2028           
=========================================
  Files           338      338           
  Lines          5850     5850           
  Branches       1066     1066           
=========================================
  Hits           4715     4715           
  Misses          564      564           
  Partials        571      571

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5f41ea5...447ca33. Read the comment docs.

`Detekt` gradle task is marked as `@CacheableTask` but it's input source files are
marked with `PathSensitivity.ABSOLUTE` annotation from `source` property defined in
parent `SourceTask`.

Having task inputs with absolute path sensitivity effectively disables cache reusability:
https://guides.gradle.org/using-build-cache/#relocatability
@3flex 3flex merged commit f04c215 into detekt:master Dec 17, 2019
@3flex
Copy link
Member

3flex commented Dec 17, 2019

Thanks for picking that up, plus the fix!

@plastiv
Copy link
Contributor Author

plastiv commented Dec 18, 2019

@3flex is there a way to get a snapshot for gradle-plugin? I don't see it being published here https://oss.jfrog.org/artifactory/webapp/#/artifacts/browse/tree/General/oss-snapshot-local/io/gitlab/arturbosch/detekt

@plastiv plastiv deleted the sp_fix_cache_relocation branch December 18, 2019 12:56
@3flex
Copy link
Member

3flex commented Dec 20, 2019

Not sure, I don't have access to publish artifacts. @arturbosch do you know if anything can be done here?

@plastiv consider opening a new issue to track this, thanks!

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.

Gradle cache restoration issue
5 participants