mirror of
https://github.com/adamhathcock/sharpcompress.git
synced 2026-02-03 21:23:38 +00:00
[PR #981] [CLOSED] Fix ~7x performance regression in ArchiveFactory.Open() by deferring stream buffering #1397
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/adamhathcock/sharpcompress/pull/981
Author: @Copilot
Created: 10/27/2025
Status: ❌ Closed
Base:
master← Head:copilot/fix-decompression-performance-issue📝 Commits (3)
2927290Initial planf27ea2dInitial plan for decompression performance fix3cc4cceFix decompression performance by delaying stream wrapping📊 Changes
2 files changed (+5 additions, -4 deletions)
View changed files
📝
src/SharpCompress/Archives/ArchiveFactory.cs(+2 -1)📝
src/SharpCompress/packages.lock.json(+3 -3)📄 Description
Opening archives with
ArchiveFactory.Open()became ~7x slower after buffering was added to stream wrapping. The buffering was applied before archive format detection, causing repeated buffer invalidations during theIsArchive()probe sequence as each factory seeks through the stream.Changes
SharpCompressStreambuffering to occur afterFindFactory()completes format detectionfactory.Open()All 480 tests pass.
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.