From 6081d11b48618a38910718aad1e38019f21392b5 Mon Sep 17 00:00:00 2001 From: Yonghye Kwon Date: Tue, 10 Mar 2026 10:18:44 +0900 Subject: [PATCH] fix: enable deflate feature for zip crate to support GitHub archive extraction GitHub zipball archives use deflate compression, but the zip crate was configured with default-features = false which disabled all decompression methods. This caused "Compression method not supported" errors when converting GitHub URLs (e.g. `convert https://github.com/user/repo`). The deflate feature uses pure Rust (flate2/rust_backend), safe for all targets including wasm32. Co-Authored-By: Claude Opus 4.6 Signed-off-by: Yonghye Kwon --- Cargo.lock | 18 ++++++++++++++++-- Cargo.toml | 2 +- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 2ca9c92..1c08dfc 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -639,9 +639,9 @@ checksum = "09edd9e8b54e49e587e4f6295a7d29c3ea94d469cb40ab8ca70b288248a81db2" [[package]] name = "libc" -version = "0.2.182" +version = "0.2.183" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6800badb6cb2082ffd7b6a67e6125bb39f18782f793520caee8cb8846be06112" +checksum = "b5b646652bf6661599e1da8901b3b9522896f01e736bad5f723fe7a3a27f899d" [[package]] name = "linux-raw-sys" @@ -2074,9 +2074,11 @@ dependencies = [ "crc32fast", "crossbeam-utils", "displaydoc", + "flate2", "indexmap", "memchr", "thiserror", + "zopfli", ] [[package]] @@ -2084,3 +2086,15 @@ name = "zmij" version = "1.0.21" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa" + +[[package]] +name = "zopfli" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f05cd8797d63865425ff89b5c4a48804f35ba0ce8d125800027ad6017d2b5249" +dependencies = [ + "bumpalo", + "crc32fast", + "log", + "simd-adler32", +] diff --git a/Cargo.toml b/Cargo.toml index c887185..eee776c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -20,4 +20,4 @@ serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" tempfile = "3.17" toml = "0.8" -zip = { version = "2.2", default-features = false } +zip = { version = "2.2", default-features = false, features = ["deflate"] }