libgit2 / libgit2/libgit2sharp

FileHistory return empty enumerable for deleted files

オープン
#1,612 コメント 3 件 リアクション 1 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

主要言語
C#
スター
3.5k
フォーク
925
PR マージ指標
30日以内にマージされた PR はありません

説明

Reproduction steps
  1. Create a file and commit
  2. Delete the file and commit
  3. Query the log for that specific file: IEnumerable<LogEntry> logs = repo.Commits.QueryBy(fileName);
Expected behavior

The logs enumerable contains 2 entries (initial commit and delete commit)

Actual behavior

The logs enumerable is empty

Version of LibGit2Sharp (release number or SHA1)

v0.25.2

Operating system(s) tested; .NET runtime tested

Windows 7
.Net Framework 4.7.1

Note that git log will also (by default) not return any results when specifying the file name only:

image

However, when telling git explicitly if a revision or a file is specified, git log will show the expected results:

image

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

エントリポイント repo.Commits.QueryBy(fileName) から開始し、issue に記載されている削除されたファイルの履歴を再現します。ファイル引数の処理を、報告で示されている git log の動作と比較します。クエリが初期コミットと削除コミットの両方を返し、そのシーケンスをカバーするリグレッションテストがあることを完了条件とします。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
csharp, git
領域
devtools
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
48/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。