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

Cache cleanup is incompatible with configuration-cache reuse #19

Open
bigdaz opened this issue Jan 13, 2024 · 0 comments
Open

Cache cleanup is incompatible with configuration-cache reuse #19

bigdaz opened this issue Jan 13, 2024 · 0 comments
Labels
bug Something isn't working in:cache-cleanup

Comments

@bigdaz
Copy link
Member

bigdaz commented Jan 13, 2024

When setting gradle-home-cache-cleanup: true, the action will attempt to remove all unused files from Gradle User Home before saving the state.
When running a build with state loaded from the configuration-cache, many files in Gradle User Home (eg dependency jars) are not necessarily recorded as being used during the build.

Taken together, this means that after a successful build with configuration-cache reuse, the saved Gradle User Home will have no dependencies. This can result in a ClassNotFoundException failure in subsequent builds.

@bigdaz bigdaz transferred this issue from gradle/gradle-build-action Feb 9, 2024
@bigdaz bigdaz added the bug Something isn't working label Feb 9, 2024
@bigdaz bigdaz changed the title Cache cleanup incompatible with configuration-cache reuse Cache cleanup is incompatible with configuration-cache reuse Feb 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working in:cache-cleanup
Projects
None yet
Development

No branches or pull requests

1 participant