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

LFS support broke #132

Closed
Doomsdayrs opened this issue Dec 8, 2022 · 3 comments
Closed

LFS support broke #132

Doomsdayrs opened this issue Dec 8, 2022 · 3 comments

Comments

@Doomsdayrs
Copy link

Doomsdayrs commented Dec 8, 2022

Description

At some point within the last month, git-lfs support broke itself again.

Expected Behavior

git-lfs properly pulls objects.

Actual behavior

flatpak run org.flatpak.Builder build --force-clean build *.yaml log.txt

Additional Context

I tested with flatpak-builder as installed via rpm, version 1.2.3 and it worked fine.

image

Experimenting with the flatpak version of the builder, I discovered that while the builder does use the same version of the flatpak-builder, it has something preventing the proper pull via git-lfs.

I experimented with the flatpak versions of builder, from the current version to all the way back to 567fcc0 .

This is my limit of knowledge currently.

@Doomsdayrs
Copy link
Author

Doomsdayrs commented Dec 9, 2022

Alright, so something is up.

Enter the flatpak runtime via

flatpak run --command=bash org.flatpak.Builder

Then I cloned the repository via

$ git clone https://github.com/Revolutionary-Games/Thrive-Launcher.git
Cloning into 'Thrive-Launcher'...
remote: Enumerating objects: 4707, done.
remote: Counting objects: 100% (1433/1433), done.
remote: Compressing objects: 100% (334/334), done.
remote: Total 4707 (delta 1131), reused 1348 (delta 1092), pack-reused 3274
Receiving objects: 100% (4707/4707), 3.93 MiB | 10.70 MiB/s, done.
Resolving deltas: 100% (3292/3292), done.

All cloned fine and dandy.

$ cd Thrive-Launcher/
$ git lfs fetch --all
fetch: 71 objects found, done.                                                                                                                                                                                                                
fetch: Fetching all references...

git lfs fully fetched, no issues.

So this means that the patch is improperly using git, I narrowed it down via modifying the patch and figured out that the following patch is broken.

@@ -606,6 +616,15 @@ builder_git_mirror_repo (const char     *repo_location,
                     was_shallow ? "--unshallow" : NULL,
                     NULL))
             return FALSE;
+
+          g_print ("Fetching LFS assets\n");
+          if (!git (mirror_dir, NULL, 0, error,
+                    "lfs", "fetch", "--all", NULL))
+            {
+              git (mirror_dir, NULL, 0, error,
+                   "lfs", "logs", "last", NULL);
+              return FALSE;
+            }
         }
 
       if (alternates)

@Doomsdayrs
Copy link
Author

But it does not make sense, why is it throwing a 404, no matter how long I look at it I do not understand.

@bbhtt bbhtt added the bug Something isn't working label Feb 29, 2024
@bbhtt
Copy link
Contributor

bbhtt commented Jun 19, 2024

This is an issue with the source repository here. See flathub/com.revolutionarygamesstudio.ThriveLauncher#50 (comment)

The lfs patch seems to work fine with other LFS repos.

@bbhtt bbhtt closed this as not planned Won't fix, can't repro, duplicate, stale Jun 19, 2024
@bbhtt bbhtt removed the bug Something isn't working label Jun 19, 2024
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

No branches or pull requests

2 participants