Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: handle edge case with same review sha after force-push #122

Merged
merged 1 commit into from
Oct 11, 2023

Conversation

Balvajs
Copy link
Owner

@Balvajs Balvajs commented Oct 8, 2023

When the force-push doesn't rewrite the whole history, then it may happen that the review SHA and head SHA are the same. This means that the changed files can't be resolved, like when the force-push rewrites the whole history, but the action doesn't recognize that it's "force-push" scenario and doesn't remove any review.

Simply comparing the review SHA and head SHA can be used to catch this scenario and then treat it as a force-push.

Fixes #121

@Balvajs Balvajs self-assigned this Oct 8, 2023
@Balvajs Balvajs marked this pull request as ready for review October 11, 2023 10:25
@Balvajs Balvajs merged commit 733cfd2 into main Oct 11, 2023
@Balvajs Balvajs deleted the feat/handle-same-sha-after-force-push branch October 11, 2023 10:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Logging issues in case of force-push
1 participant