Deduplicator: xxh32 digest can collide on large ZIMs
Maintainer thường phản hồi trong vòng 1 ngày
@i-varunsharma đang làm issue này rồi.
Từ ngày 4/12/2026.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
Follow-up from openzim/ifixit#165, as suggested by @benoit74.
Deduplicator keys items by an xxh32 digest only (zim/dedup.py), which is 32-bit. With n deduplicated items the expected number of collisions is about n²/2³³, so roughly 1 around 100k items and ~30 around 500k. A full iFixit ZIM has a lot of images, so two different images could end up with the same digest, and the second one would silently become an alias to the wrong image.
A few options:
- also store the content size with the digest and compare both, as benoit74 suggested. Cheap, but it only lowers the odds
- switch to a 128 bit hash (xxhash has
xxh3_128), which is about as fast and makes collisions practically impossible - both
My suggestion would be xxh3_128 + size as the key. I can open a PR once we agree on the approach.
- Ngôn ngữ chính
- Python
- Star
- 33
- Fork
- 36
- Merge trung bình
- 1 ngày 10 giờ
- Pull request đã merge (30 ngày)
- 19
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của openzim/python-scraperlib
-
handle_user_provided_file leaves an empty temp fileCó thể đã có người làm @kevincommits đã nhận 3 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
openzim/python-scraperlib#414 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
HtmlRewriter: title is cut at the first `&` (entity or bare ampersand)Có thể đã có người làm @rajanpanth đã nhận 23 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 77/100
openzim/python-scraperlib#401 · 3 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[next major] Remove deprecated 'convert' parameter for optimize_image function inside optimization.pyCó thể đã có người làm @Sriram-Nambiar đã nhận 51 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
openzim/python-scraperlib#292 · 1 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Metadata accepts empty BytesIO/file values although empty is not allowedCó thể đã có người làm @playlikeboy đã nhận 1 ngày trước. Đang mở
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 25/100
openzim/python-scraperlib#422 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Detect and recover malformed inline data URLs missing the data: schemeCó thể đã có người làm @Sriram-Nambiar đã nhận 2 ngày trước. Đang mở
openzim/python-scraperlib#420 · 2 reaction · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của openzim/python-scraperlib
Issue tương tự
-
Relatório de erro do LinuxToysĐang mởauto-reported bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
Maintainer thường phản hồi trong vòng 1 ngày
-
stix-atlas.json: the same relationship id is used for several different mitigates relationshipsĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
-
backend bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
nolte/kamerplanter#3193 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
soup prune-prompt exits 1 after writing its output on a file over 100,000 rows, and reports a capped row count otherwiseCó thể đã có người làm @abdulwaarith0 đã nhận hôm nay. Đang mởneeds-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
MakazhanAlpamys/Soup#3690 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày