Skip to content

fix: addition of some commits are ridiculous huge#7719

Merged
abeizn merged 1 commit into
mainfrom
kw-fix-commit-addition
Jul 11, 2024
Merged

fix: addition of some commits are ridiculous huge#7719
abeizn merged 1 commit into
mainfrom
kw-fix-commit-addition

Conversation

@klesh
Copy link
Copy Markdown
Contributor

@klesh klesh commented Jul 11, 2024

Context

Previously, I fixed #7426 with #7458 which seemed to be working just fine, but it turned out to be NOT true, it merely push the problem upstream without actually fixing anything.

The problem: when doing a shallow clone, commits are truncated at some point, which means there are some commits that have parents that do not exist in the cloned local repo, thus a huge addition if we calculate the stat for those commits because they are compared against nothing.

PR #7458 deepened the commit history by 1 step solving the stat of the newly added commits, but it failed to skip those parent commits and overwrite the correct values in the database.

The PR finished the leftover job.

How to apply

This is quite a severe bug that affects almost every single user.
Please upgrade to a fixed version and then do a Full Refresh for your projects to fix the incorrect LOC values.

@dosubot dosubot Bot added size:M This PR changes 30-99 lines, ignoring generated files. component/plugins This issue or PR relates to plugins labels Jul 11, 2024
@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label Jul 11, 2024
@abeizn abeizn merged commit 5889a08 into main Jul 11, 2024
@abeizn abeizn deleted the kw-fix-commit-addition branch July 11, 2024 08:04
@github-actions
Copy link
Copy Markdown
Contributor

🤖 Target: #release-v1.0 cherry pick finished successfully 🎉!

@github-actions github-actions Bot added the bot/auto-cherry-pick-completed auto cherry pick completed label Jul 11, 2024
abeizn pushed a commit that referenced this pull request Jul 11, 2024
Co-authored-by: Klesh Wong <zhenmian.huang@merico.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bot/auto-cherry-pick-completed auto cherry pick completed component/plugins This issue or PR relates to plugins lgtm This PR has been approved by a maintainer needs-cherrypick-v1.0 size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug][GitHub] LOC additions/deletions are wrong for the first commit in the specified time range

2 participants