Skip to content

GITHUB_SHA is the prior commit's hash, not the current commit's #4574

Description

@actual-nh

What article on docs.github.com is affected?

https://docs.github.com/en/actions/reference/environment-variables

What part(s) of the article would you like to see updated?

See https://github.laiyagushi.community/t/commit-sha-by-github-action-always-one-behind-the-commit-sha-displayed-in-github-gui/17979; GITHUB_SHA is not the actual commit being tested. It is the previous commit (which is rather useless for coordination purposes with other sites; see #4422 for more on this, including an example of the lack of correspondence).

Additional context

I'd submit a PR, but I don't think it would be advisable - I am currently a bit irked about all this. Of course, if anyone has problems rewriting it, getting someone to fix it so it works the way it currently reads is an alternative 😁

Metadata

Metadata

Assignees

No one assigned

    Labels

    actionsThis issue or pull request should be reviewed by the docs actions team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions