vscode-gitlens icon indicating copy to clipboard operation
vscode-gitlens copied to clipboard

GitLens cannot display submodule diffs

Open vadimcn opened this issue 5 years ago • 2 comments

  • GitLens Version: 10.2.1
  • VSCode Version: 1.45.1
  • OS Version: Ubuntu 20.04

Steps to Reproduce:

  1. Create git repository with submodule(s), create a commit involving a submodule.
  2. In branch history locate and expand that commit. Click on the submodule.

Result: Error "Unable to open '<submodule> <hash> ... "
Looks like VSCode is trying to compare submodule directory as if it were a file.

Expected: Display submodule hash diff, the way VSCode's git integration does this:

diff --git a/submodule b/submodule
--- a/submodule
+++ b/submodule
@@ -1 +1 @@
-Subproject commit b1601e42183b31af1afc6ceedd4cb9b3efb27f0d
+Subproject commit 388ba770105a27e5589e55ad56dcf9dbd407d134

vadimcn avatar Jun 05 '20 21:06 vadimcn

I can confirm this on GitLens 10.2.2, VSCode 1.46.1, Win 10.

Unable to open '<submodule> <hash> ↔ <submodule>': Unable to read file '<path to submodule>' (Error: Unable to read file '<path to submodule>' that is actually a directory).

What I would like to see, is the difference between the commits that the submodule is/was pointing to.

am9417 avatar Jul 14 '20 06:07 am9417

5 years later – still an issue...
GitLens 17.4.1, VSCode 1.103.2, Win 11.

GlebMorgan avatar Sep 19 '25 15:09 GlebMorgan