Bisect exports commits with git archive, which omits export-ignore paths
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 69/100
調査の方向性
Read internal/gitx/gitx.go around Archive and ExportIndex/writeBlobs, then inspect the sole caller and existing error handling in internal/engine/debug.go. Start by tracing how commit trees and blobs are exported and how untar applies file rules. Add coverage for both acceptance criteria: an export-ignore directory remains present and an export-subst file retains its committed bytes; run make test-short.
索引モデルが issue の本文から書いたものです。
説明
Summary
The bisect probe of spackle debug --good exports each commit with git archive, which applies the export-ignore and export-subst attributes, so the probe can run against a tree that is missing committed files.
Where
internal/gitx/gitx.go:754-761(Archive; the comment says the export holds the bytes that were committed)internal/engine/debug.go:652,:664(the only caller, and the "test does not exist" message)
Details
git archive leaves out paths marked export-ignore in the archived tree's .gitattributes and rewrites $Format:...$ placeholders in export-subst files. Nothing in the repository mentions either attribute. The git behavior is documented in gitattributes(5); not run during the audit, since it needs a model and a container runtime.
Impact
For a repository whose .gitattributes marks its tests or fixtures export-ignore (common in packages that ship archives), every bisect probe runs on a tree without those files. With --test, the first probe ends with "the test ... does not exist at commit HEAD" although the test is committed. With --issue, the reproduction runs against an incomplete tree and can label commits wrongly. The working-tree reproduction that precedes bisect is not affected, so the two disagree.
Steps to reproduce
- In a repository with
tests/ export-ignorein.gitattributesand a failing test undertests/, runspackle debug --test <name> --good <older-rev> . - The working-tree reproduction succeeds, then bisect reports that the test does not exist at HEAD.
Suggested fix
Export the tree without archive attributes: list it with git ls-tree -r -z <rev> and read the blobs with git cat-file --batch, as ExportIndex / writeBlobs already do for the index (the helpers can be shared), keeping the regular-file-only and size rules of untar.
Acceptance criteria
- A test exports a commit whose
.gitattributesmarks a directoryexport-ignoreand finds the directory in the export - An
export-substfile is exported byte for byte
Related: #84, #41
Getting started
- Relevant files: internal/engine/debug.go, internal/gitx/gitx.go
- How to run tests:
make test-short(Unix) or.\make.ps1 test-short(Windows PowerShell);make lintbefore you call it done - Related docs: CONTRIBUTING.md, docs/ARCHITECTURE.md
Filed by repo-audit/full-audit at 50e92ec. Severity: low. Effort: M. audit-key: bug|internal/gitx/gitx.go|Archive-export-ignore
- 主要言語
- Go
- スター
- 0
- フォーク
- 1
- 平均マージ
- 8時間 14分
- マージ済み PR(30日)
- 3
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
TMHSDigital/Spackle のほかの issue
-
ci good first issue severity: low
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
TMHSDigital/Spackle#206 ·
メンテナーはふだん 1 日以内に返信
-
ci severity: low
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
TMHSDigital/Spackle#205 ·
メンテナーはふだん 1 日以内に返信
-
bug good first issue severity: low
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
TMHSDigital/Spackle#199 ·
メンテナーはふだん 1 日以内に返信
-
bug good first issue severity: low
難易度 2/5 1〜3時間 初心者へのやさしさ 87/100
TMHSDigital/Spackle#195 ·
メンテナーはふだん 1 日以内に返信
-
documentation good first issue severity: medium
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
TMHSDigital/Spackle#188 ·
メンテナーはふだん 1 日以内に返信
TMHSDigital/Spackle の issue をすべて見る
似ている issue
-
bug effort:s impact:med raised-by:worker risk:low to:worker
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
medici-finance/assay#8120 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
factory:subtask
難易度 1/5 1時間未満 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
agent-substrate/substrate#4308 ·
メンテナーはふだん 2 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
celestiaorg/celestia-app#8877 ·
メンテナーはふだん 1 日以内に返信
-
sweep
難易度 1/5 1時間未満 初心者へのやさしさ 84/100
bketelsen/truenas-mcp#112 ·
メンテナーはふだん 1 日以内に返信