-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
Garbage Collection LFS Pointer deletes inuse LFS Objects #31271
Labels
issue/critical
This issue should be fixed ASAP. If it is a PR, the PR should be merged ASAP
topic/lfs
type/bug
Milestone
Comments
Confirmed that it can be reproduced. The problem arises with gogit enabled editions:
|
GiteaBot
pushed a commit
to GiteaBot/gitea
that referenced
this issue
Aug 9, 2024
Fix go-gitea#31271. When gogit is enabled, `IsObjectExist` calls `repo.gogitRepo.ResolveRevision`, which is not correct. It's for checking references not objects, it could work with commit hash since it's both a valid reference and a commit object, but it doesn't work with blob objects. So it causes go-gitea#31271 because it reports that all blob objects do not exist.
wolfogre
added a commit
that referenced
this issue
Aug 9, 2024
Backport #31790 by @wolfogre Fix #31271. When gogit is enabled, `IsObjectExist` calls `repo.gogitRepo.ResolveRevision`, which is not correct. It's for checking references not objects, it could work with commit hash since it's both a valid reference and a commit object, but it doesn't work with blob objects. So it causes #31271 because it reports that all blob objects do not exist. Co-authored-by: Jason Song <[email protected]>
project-mirrors-bot-tu bot
pushed a commit
to project-mirrors/forgejo-as-gitea-fork
that referenced
this issue
Jan 23, 2025
Backport go-gitea#31790 by @wolfogre Fix go-gitea#31271. When gogit is enabled, `IsObjectExist` calls `repo.gogitRepo.ResolveRevision`, which is not correct. It's for checking references not objects, it could work with commit hash since it's both a valid reference and a commit object, but it doesn't work with blob objects. So it causes go-gitea#31271 because it reports that all blob objects do not exist. Co-authored-by: Jason Song <[email protected]> (cherry picked from commit 144648a)
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
issue/critical
This issue should be fixed ASAP. If it is a PR, the PR should be merged ASAP
topic/lfs
type/bug
Description
Hallo Community,
i noticed that on my Gitea Platform all old LFS Files are lost. Currently i only have LFS files which are 3 days old. And 3 days ago i manually run the Garbage Collection for all repositories and Garbage Collection LFS pointers.
I now reproduced this issue with setting the config as follows for that task and uploaded some lfs files an hour ago.
All LFS Files are gone again. And the Log looks not to be conclusive at all...
The Admin pannel shows that the task was done at 12:11:43 and i see the gc_lfs but there is not more than that.
Gitea Version
1.21.11
Can you reproduce the bug on the Gitea demo site?
No
Log
Screenshots
No response
Git Version
2.42.0, Wire Protocol Version 2 Enabled
Operating System
Windows
How are you running Gitea?
Windows Server: gitea-1.21.11-gogit-windows-4.0-amd64
Database
MySQL/MariaDB
The text was updated successfully, but these errors were encountered: