Repository navigation
Audit only the newest commit of a published main - #9
Merged
Merged
Conversation
On a checkout whose HEAD is already the remote default branch, the release audit checked every author identity in the public history, so each push to main failed on commits that are published and cannot change. It now checks the newest commit there, as its comment said. Branches still have every commit since the published base checked, and a repository with no remote base still has its whole history checked.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes the
CIworkflow green onmain. Since 0.6.0 every push tomainhas failed at the release audit step (latest: https://github.com/renezander030/graphiti-local/actions/runs/38053609016) withgit metadata: sensitive author identity. Ruff and pytest pass in those runs.Cause
On a push to
main, the checked-out HEAD is the published base itself, soidentity_revision()has no unpublished range. It returned"HEAD", andgit log HEADwalks the whole history. The comment there says "Check its tip". Four September commits in the public history carry a personal address. They are published and cannot change, so the step failed on every push.Fix
identity_revision()returns thegit logarguments to audit:origin/mainmain(HEAD is the base)-1 HEAD)So a push still cannot introduce a personal identity on
main, and branch commits are still all checked.Verification
tests/test_release_audit.pyrun the audit against a real temporary git repo:main's audit and passes here;3f05407(HEAD =origin/main), the exact state of the red run:main's audit fails, this audit passes.uv run ruff check .: pass.uv run pytest: 172 passed. The audit on this branch's range passes.mainturns green with the push of the merge commit, since the newest commit is then the squash under the GitHub noreply address.