gradle / gradle-build-action

Execute your Gradle build and trigger dependency submission
https://github.com/marketplace/actions/gradle-build-action
MIT License
679 stars 97 forks source link

Cache key Validation Error when workflow name contains a comma #756

Closed jebl01 closed 1 year ago

jebl01 commented 1 year ago

Our workflows contains commas in their names, this now makes the build fail with the following error:

Error: ValidationError: Key Validation Error: v8-gradle|Linux|Build, Test & Create Release-build[37a6259cc0c1dae299a7866489dff0bd]-d2138fa1b61e6a9ab14f6b45751a8118e6a378bb cannot contain commas.
ValidationError: Key Validation Error: v8-gradle|Linux|Build, Test & Create Release-build[37a6259cc0c1dae299a7866489dff0bd]-d2138fa1b61e6a9ab14f6b45751a81[18](https://github.com/webbhalsa/kry-medical-record/actions/runs/5409195640/jobs/9829089990#step:7:20)e6a378bb cannot contain commas.
    at checkKey (/home/runner/work/_actions/gradle/gradle-build-action/v2/dist/main/index.js:75:15)
    at Object.<anonymous> (/home/runner/work/_actions/gradle/gradle-build-action/v2/dist/main/index.js:108:13)
    at Generator.next (<anonymous>)
    at /home/runner/work/_actions/gradle/gradle-build-action/v2/dist/main/index.js:38:71
    at new Promise (<anonymous>)
    at __webpack_modules__.7799.__awaiter (/home/runner/work/_actions/gradle/gradle-build-action/v2/dist/main/index.js:34:12)
    at Object.restoreCache (/home/runner/work/_actions/gradle/gradle-build-action/v2/dist/main/index.js:98:12)
    at /home/runner/work/_actions/gradle/gradle-build-action/v2/dist/main/index.js:64485:47
    at Generator.next (<anonymous>)
    at /home/runner/work/_actions/gradle/gradle-build-action/v2/dist/main/index.js:64381:71

Most likely this is the commit that causes this: https://github.com/gradle/gradle-build-action/commit/2bf6bc364674627d14824f75cb987b3dee0df05e

kimakunc commented 1 year ago

same problem, using the commit hash like so works for me: i.e. : gradle/gradle-build-action @ 631021bf98316c7b544edd3a462b56f7539303d6

bigdaz commented 1 year ago

Thanks for the report. I'll get a fix out ASAP. In the meantime you can continue to use v2.4.2

bigdaz commented 1 year ago

v2.5.1 was just released which should fix this issue. Apologies for the interruption!