public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Filipe Rosset <rosset.filipe@gmail.com>
To: git-commits@fedoraproject.org
Subject: [rpms/git-lfs] f45: fix(git-lfs): run git maintenance synchronously during %check to stop flaky t-prune.sh
Date: Sun, 16 Aug 2026 02:49:27 GMT	[thread overview]
Message-ID: <178684856743.1.8203532286202834738.rpms-git-lfs-07a19b0f5e84@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : rpms/git-lfs
            Branch : f45
            Commit : 07a19b0f5e841934354eafe2282bb0c1633a244a
            Author : Filipe Rosset <rosset.filipe@gmail.com>
            Date   : 2026-08-13T21:33:16-03:00
            Stats  : +7/-0 in 1 file(s)
            URL    : https://src.fedoraproject.org/rpms/git-lfs/c/07a19b0f5e841934354eafe2282bb0c1633a244a?branch=f45

            Log:
            fix(git-lfs): run git maintenance synchronously during %check to stop flaky t-prune.sh

Git 2.54 switched the post-commit `git maintenance run --auto` job to the 'geometric' strategy, dropping the repack trigger from 6700 to ~100 loose objects. t-prune.sh commits 1000 files then runs `git lfs prune`, so the detached background repack races prune and intermittently fails with 'missing object'.

Set maintenance.autoDetach=false for the test suite so the post-commit repack runs in the foreground and finishes before prune, closing the race while keeping the maintenance path exercised. Mirrors git's own test-suite fix for the same geometric-strategy race (git.git 09505b1). Scoped to the throwaway test repos; the shipped binary is unchanged.

Reported upstream: git-lfs/git-lfs#6309

Resolves: rhbz#2503921

---
diff --git a/git-lfs.spec b/git-lfs.spec
index e8f1af3..9a9e826 100644
--- a/git-lfs.spec
+++ b/git-lfs.spec
@@ -127,6 +127,13 @@ exit 0
 
 
 %check
+# t-prune.sh commits 1000 files then runs `git lfs prune`. On git 2.54+ the default 'geometric'
+# maintenance strategy fires a detached background repack (at ~100 loose objects) that races
+# prune and intermittently fails with 'missing object'. Run maintenance synchronously so the
+# repack finishes first -- same fix as git's own test suite (git.git 09505b1). Upstream:
+# https://github.com/git-lfs/git-lfs/issues/6309
+export GIT_CONFIG_COUNT=1 GIT_CONFIG_KEY_0=maintenance.autoDetach GIT_CONFIG_VALUE_0=false
+
 %go_vendor_license_check -c %{S:5}
 %if %{with check}
 %gocheck2

                 reply	other threads:[~2026-08-16  2:49 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178684856743.1.8203532286202834738.rpms-git-lfs-07a19b0f5e84@fedoraproject.org \
    --to=rosset.filipe@gmail.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox