Repository navigation
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #47 +/- ##
==========================================
+ Coverage 96.80% 96.93% +0.12%
==========================================
Files 6 6
Lines 2065 2151 +86
==========================================
+ Hits 1999 2085 +86
Misses 66 66 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
pack-objects writes nothing while counting, so it never got SIGPIPE and kept packing for minutes after the client left. Assisted-by: Claude:claude-opus-5-5
Exiting without reading raced the query write into EPIPE, so the cat-file failure branch was hit only some of the time. Assisted-by: Claude:claude-opus-5-5
Temikus
force-pushed
the
fix/kill-upload-pack-on-disconnect
branch
from
October 13, 2026 01:11
1d924df to
facb844
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What kind of change does this PR introduce?
Summary
Point 3 follow-up from #45. When a client hangs up mid-serve,
upload-packand itspack-objectschild kept running.pack-objectswrites nothing while it counts and compresses, so it never gets SIGPIPE and can pack for minutes with nobody reading.upload-packnow runs in its own process group.TimedReadersignals aoneshotat EOF; if the stream is dropped before that, the reaper SIGKILLs the group before reaping, so the group ID cannot be recycled. The reaper is spawned before the request write, so a request dropped mid-write is cleaned up too.rustix(unix only) is a new direct dependency for a safekillpg. It was already in the lockfile viatempfile.Tests
The e2e test uses a fake
git_binarywhoseupload-packstarts a silent grandchild, then drops the TCP connection and checks the grandchild dies. It fails onmainand passes here.Checklist
cargo fmt --all --check,cargo clippy --all-targets --all-features --locked -- -D warnings,cargo test --all-featuresAssisted-by:trailer (see CONTRIBUTING.md / AGENTS.md)Breaking change?
No.