gradle / wrapper-validation-action

Gradle Wrapper Validation Action
https://github.com/marketplace/actions/gradle-wrapper-validation
MIT License
257 stars 57 forks source link

gradle-wrapper failing validation after downloading from services.gradle.org #61

Closed perry-mitchell closed 2 months ago

perry-mitchell commented 2 years ago

Apologies if I'm missing something HUGE here, but I'm downloading gradle-6.8.3-bin.zip from https://services.gradle.org/distributions/ (https://services.gradle.org/distributions/gradle-6.8.3-bin.zip), and taking the gradle-wrapper-6.8.3.jar file from the lib directory to add to my project. After checking that the version is correct in the gradle wrapper properties, I push and always seem to get the same validation error:

Run gradle/wrapper-validation-action@e6e38bacfdf1a337459f332974bb2327a31aaf4b
Error: Gradle Wrapper Validation Failed!
  See https://github.com/gradle/wrapper-validation-action#reporting-failures
✗ Found unknown Gradle Wrapper JAR files:
  c37c0506af1f7314367d3dd5b3f3c8264387cd3c15774ea6c76d28b897254fd9 android/gradle/wrapper/gradle-wrapper.jar
✓ Found known Gradle Wrapper JAR files:
  381dff8aa434499aa93bc25572b049c8c586a67faff2c02f375e4f23e17e49de node_modules/@react-native-community/clipboard/android/gradle/wrapper/gradle-wrapper.jar
  381dff8aa434499aa93bc25572b049c8c586a67faff2c02f375e4f23e17e49de node_modules/@react-native-community/slider/android/gradle/wrapper/gradle-wrapper.jar
  33ad4583fd7ee156f533778736fa1b4940bd83b433934d1cc4e9f608e99a6a89 node_modules/react-native-gradle-plugin/gradle/wrapper/gradle-wrapper.jar
  16caeaf66d57a0d1d2087fef6a97efa62de8da69afa5b908f40db35afc4342da node_modules/react-native-secure-storage/android/gradle/wrapper/gradle-wrapper.jar
  98420079ffe3e24b1013180d9b9bc2e2ee6a9d867ee232004b75a961d9c18e27 node_modules/react-native-secure-storage/example/android/gradle/wrapper/gradle-wrapper.jar
  33ad4583fd7ee156f533778736fa1b4940bd83b433934d1cc4e9f608e99a6a89 node_modules/react-native/template/android/gradle/wrapper/gradle-wrapper.jar

I feel like I'm retrieving the correct version from the correct location, but the reported checksum doesn't match that reported here. What am I doing wrong?

rnc commented 1 year ago

You might find it easier to do:

./gradlew wrapper --gradle-version=6.8.3 --distribution-type=bin

Or:

./gradlew wrapper --gradle-version=6.8.3 --distribution-type=bin --gradle-distribution-sha256-sum=e996d452d2645e70c01c11143ca2d3742734a28da2bf61f25c82bdc288c9e637

(using checksums from https://gradle.org/release-checksums/)

bigdaz commented 2 months ago

Closing this issue as stale. Please open a new issue at https://github.com/gradle/actions/issues if you are still experiencing problems.