On 12/3/26 15:08, Patrick Steinhardt wrote:
> On Wed, Dec 02, 2026 at 01:23:30AM +0530, Kaartic Sivaraam wrote:
>> Range-diff vs. v4: >> >> 1: ad8fa8d872 ! 1: 2fcdeefff3 test-lib: run EXPENSIVE tests one at a time >> @@ t/test-lib.sh: test_missing_prereq= >> >> test_external_has_tap=0 >> >> ++# Remove the lock only if it still names $1 as its owner, so that >> ++# a lock someone else has just taken is left alone.
> > I feel like this comment is a bit on the verbose side as it doesn't > really provide much value over what the code already trivially tells > you, but okay. >
Makes sense. I'll drop it.
>> @@ t/test-lib.sh: fail_117 () { >> + # >> + # Another waiter may have taken it over since we >> + # looked, so only remove it if it is still the same. >> -+ if test "$(cat "$expensive_lock_" 2>/dev/null)" = "$owner" >> ++ # >> ++ # Rarely, after a holder is killed, two waiters can >> ++ # both get past this check and run together.
> > Heh, it takes courage to claim that a race happens rarely. My experience > is that no matter how unlikely a race, CI systems know to trigger that > race often enough to annoy the hell out of you. >
Haha. That makes sense. Will replace the "Rarely" part with "In some scenarios". Hope that reads better. >> ++ if remove_expensive_lock_owned_by_ "$owner"
>> + then >> -+ rm -f "$expensive_lock_" >> ++ echo >&2 "# removing stale EXPENSIVE lock left by PID $owner" >> + fi >> + continue >> + fi
> > It's a bit funny to say "removing" after you have removed the lock > already. But providing that context can definitely be helpful, I'd > assume. >
Good point. Will do a s/removing/removed/
> Anyway, my comments are really only just nits, so please feel free to > ignore them. Other than that I'm happy with this version, thanks! >
Cool. Thank you for the review!
-- Sivaraam