mhutchie / vscode-git-graph

View a Git Graph of your repository in Visual Studio Code, and easily perform Git actions from the graph.
https://marketplace.visualstudio.com/items?itemName=mhutchie.git-graph
Other
1.97k stars 260 forks source link

When comparing between different branches, an invalid commit is used as source. #814

Open MeroZemory opened 5 months ago

MeroZemory commented 5 months ago

I compared commits from different branches (from 994ec6bc5194ac7fd323033cc83cebf2d0df7f42 to b73b6b229e0fa3ef10f8ebd1ebbfbd72011a6f7f), but the comparison of a specific file (settings. json), the comparison result is actually a different comparison result (from 9f31ac4e4891b8641f655ecc18c1e6578e206647 to b73b6b229e0fa3ef10f8ebd1ebbfbd72011a6f7f).

This was the case no matter which commit in the new branch I tried to compare.

To reproduce this, I did a simple test of creating a new branch by checking out to the old commit from an new repository, committing a few changes, and naming the branch, but I failed to reproduce it.

main branch:

Steps to Reproduce Steps to reproduce the behaviour:

  1. Clone: https://github.com/MeroZemory/temp-bug-report.git
  2. Compare commits from 994ec6bc to b73b6b22

Environment

Screenshots

994ec6bc 994ec6bc^ <-> 994ec6bc

b73b6b22 b73b6b22^ <-> b73b6b22

from 994ec6bc to b73b6b22 994ec6bc <-> b73b6b22

from 994ec6bc to b73b6b22 (2) 994ec6bc <-> b73b6b22

Additional Context Git Graph OUTPUT: [2024-04-10 17:58:08.081] > git diff --name-status --find-renames --diff-filter=AMDR -z 994ec6bc5194ac7fd323033cc83cebf2d0df7f42 b73b6b229e0fa3ef10f8ebd1ebbfbd72011a6f7f [2024-04-10 17:58:08.083] > git diff --numstat --find-renames --diff-filter=AMDR -z 994ec6bc5194ac7fd323033cc83cebf2d0df7f42 b73b6b229e0fa3ef10f8ebd1ebbfbd72011a6f7f