libgit2 / libgit2/libgit2sharp
FullHistory method of FileHistory class, doesn't return actual history
まだ誰も着手していません。
- 主要言語
- C#
- スター
- 3.5k
- フォーク
- 925
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Code:
var _repository = new Repository(@"D:\11");
var commitFilter = new CommitFilter { SortBy = CommitSortStrategies.Topological };
var sdf = _repository.Commits.QueryBy("SPF 711 performance", commitFilter).Select(c => c.Commit).ToList();
doesn't return history, while existing of 7 commits.

Inside the method FullHistory iterating through commits stops when reaching commit
4bf4edccaa9ce3b7f785b14939a3545c627b5dfd because of this code:
var currentTreeEntry = currentCommit.Tree[currentPath];
if (currentTreeEntry == null)
{
yield break;
}
looks like iterator cannot achieve commits which contain a history of the file because of the running into the commit which knows nothing about the file.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
FileHistory.FullHistory を見つけ、示されている Repository と CommitFilter を 7 コミットの履歴に対して使用して問題を再現します。コミット 4bf4edccaa9ce3b7f785b14939a3545c627b5dfd での反復を追跡し、currentTreeEntry が null のときに停止するのではなく、メソッドが完全なファイル履歴を返すことを確認します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- csharp, git
- 領域
- devtools
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100