Skip to content

PMD annotations are added in an (Unknown event) in a (Unnamed workflow) when used in a pull request build #2

@n-peugnet

Description

@n-peugnet

Hi, I tried to use your action but I found a bug on pull_request builds. It took me some builds to find out that the action was correctly reporting violations but not on the correct build.

On my last attempt tried to use this option of the checkout action but strangely the check was still added to the merge commit :

- uses: actions/checkout@v2
  with:
    ref: ${{ github.event.pull_request.head.sha }}

I looked a little bit at your code and I wonder if using context.ref when the check is created instead of context.sha would solve this problem (when the above option is set in the checkout action).

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationhelp wantedExtra attention is needed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions