Skip to content

error in v5.4.2 #746

@jinganix

Description

@jinganix

There are two workflows PR and CI in the repo: https://github.com/jinganix/ddz/actions

CI: https://github.com/jinganix/ddz/blob/master/.github/workflows/ci.yml
PR: https://github.com/jinganix/ddz/blob/master/.github/workflows/pr.yml

PR workflow works fine in v5.4.1 and v5.4.2:

CI workflow works fine in v5.4.1, but fails in v5.4.2:

The error message is:

Error: You have commit messages with errors

error trying to get list of pull request's commits
Cannot read property 'map' of undefined
TypeError: Cannot read property 'map' of undefined
    at getPushEventCommits (/run.js:57:56)
    at getEventCommits (/run.js:65:62)
    at commitLinterAction (/run.js:166:34)
    at Object.<anonymous> (/run.js:168:1)
    at Module._compile (node:internal/modules/cjs/loader:[10](https://github.com/jinganix/ddz/actions/runs/5632512219/job/15264988759#step:4:11)95:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:[11](https://github.com/jinganix/ddz/actions/runs/5632512219/job/15264988759#step:4:12)24:10)
    at Module.load (node:internal/modules/cjs/loader:975:32)
    at Function.Module._load (node:internal/modules/cjs/loader:816:[12](https://github.com/jinganix/ddz/actions/runs/5632512219/job/15264988759#step:4:13))
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:79:12)
    at node:internal/main/run_main_module:[17](https://github.com/jinganix/ddz/actions/runs/5632512219/job/15264988759#step:4:18):47
Error: You have commit messages with errors

The CI works fine again if I specify the version: uses: wagoid/commitlint-github-action@v5.4.1:

The error also occurred in another repo

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions