fix: SourceForge チェックサム不安定問題を根本解決 - #2
Merged
Conversation
SourceForge の CDN/ミラーが tar.gz を再圧縮することで SHA256 が 不定期に変わり、ビルドが壊れる問題 (#1) に対する恒久対策。 1. GitHub Release ミラー (deps-v1) を一次ダウンロード元として追加 - SourceForge をフォールバックとして維持 2. inner tar ハッシュ検証を追加 - gzip 展開後の tar をハッシュすることで再圧縮に対して安定 - .tar.gz ハッシュ不一致時の自動フォールバック 3. gzip マジックバイト検証を追加 - HTML エラーページの誤ダウンロードを検出 Closes #1
Docker コンテナ (ubuntu:22.04) に xxd がインストールされていないため、 gzip マジックバイト検証が常に失敗していた。 POSIX 標準の od コマンドに置き換えてポータビリティを確保。
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.
Summary
SourceForge の CDN/ミラーネットワークが
.tar.gzを定期的に再gzip圧縮することで、SHA256 ハッシュが不定期に変わりビルドが壊れる問題を根本的に解決します。根本原因(調査結果)
対策内容
deps-v1) を一次ダウンロード元として追加.tar.gzハッシュ不一致時に自動的にフォールバック変更ファイル
scripts/fetch_dependencies.sh— Linux/macOS/CI 用scripts/fetch_dependencies.ps1— Windows 用Test plan
Closes #1