Skip to content

bug: attestation git.head commit SHA is reporting the merge commit SHA instead of the actual commit #3064

@jiparis

Description

@jiparis

This issue only happens in attestations done from PRs in Github actions. Since Github creates a temporary merge commit for the PR, the attestation reports it as the commit at HEAD, instead of the latest commit in the PR (the actual branch head).

This is a known feature / issue in Github and probably others, well explained here https://www.codegenes.net/blog/get-commit-sha-in-github-actions/.

The result is that attestations end up being referred to ghost commits in the referral graph. This is specially relevant when users also create attestations from agentic workflows: local attestations don't match any PR because their commit SHAs are different (and they shouldn't)

Metadata

Metadata

Assignees

No one assigned

    Labels

    User BugbugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions