Sublime Forum

Windows problems with GPG signature

#1

When opening a repo with merge when I look in history all my signatures show up as invalid with the following message:

gpg: can’t open ‘/c/Users/tyler/AppData/Local/Temp/sub8E6E.tmp’ No such file or directory
gpg: verify signature failed: No such file or directory

gpg is all set up correctly as I’m able to run gpg and git signing works fine from command line. Any ideas? Running build 2002.

1 Like

#2

We’ve got a fix for this in the pipeline

1 Like

#3

This has not been fixed yet. Any news when it will be? Build 2020 and getting still seeing ‘Invalid’ against all the signatures

0 Likes

#4

This specific issue should be fixed in build 2020. Have you made sure gpg is in your PATH? You can see the result of running gpg by hovering over the “Invalid signature”, what does it say?

0 Likes

#5

image

Not sure many clues in the error message as there is no error number. I have checked gpg is in my path. Signing commits works as expected, just the signature is not displayed in Sublime Merge.

0 Likes

#6

Which version of Windows are you using? Which installation of gpg are you using? I can’t reproduce this on Windows 10 with the git for windows gpg.

0 Likes

#7

Ok, interesting. I was using gpg4win 3.1.11 which had gpg version 2.2.19. I removed that and reconfigured to use git for windows gpg which is version 2.2.20 and that works correctly.

1 Like

#8

I have the same issue and tried checking out the Git for Windows version of GPG, but it seems that one has issues with smart cards (YubiKey in my case).

With there only being a difference of one patch version between the two GPG versions, can that update really be what affects it?

git verify-commit <hash> works fine when I verify commits manually on the command line, signing commits works both from command line and from within Sublime Merge. It’s only the verification that fails from Sublime Merge.

Sublime Merge shows the output from gpg, but it doesn’t show how it tried to call it. Is there a way to see that so we can try the command manually and see what output it produces?

Edit:
Error from Sublime Merge: image

However, I can verify with Git manually just fine:

Edit 2:
In case it helps, here is what Process Monitor says about the operation:


So gpg gets a “SHARING VIOLATION”, whatever that means? Sublime Merge seems to create the file with “ShareMode: None” while gpg wants “ShareMode: Read”, is that the issue? (Nvm it does set ShareMode Read after)

Edit 3:
Process monitor gives us the gpg command Sublime Merge is running:
gpg --keyid-format=long --status-fd=1 --verify C:\Users\<user>\AppData\Local\Temp\sub63B7.tmp -

Unfortunately the file gets deleted immediately after so I can’t test against that file myself.

0 Likes

#9

I’m seeing a similar issue on both my Windows 10 PCs. I’ve got 2 GPG’s on my PC:

where gpg
C:\Program Files\Git\usr\bin\gpg.exe
C:\Program Files (x86)\GnuPG\bin\gpg.exe

The first one in my path (Git’s) is gpg (GnuPG) 2.2.20-unknown and the other (gpg4win’s) is gpg (GnuPG) 2.2.19

Manually verifying signatures, via git log --show-signature or git verify-commit, shows valid signatures, but SublimeMerge shows Invalid:

My error is different from others in this thread, but hoping there’s an easy fix.

Thanks for a great product! :slight_smile:

0 Likes

#10

I’m running build 2020 and having the same error:

image

I also have gpg4win installed and I can verify the commits using git verify-commit.
I’m keen to find a workaround or try a fix, as it’s quite annoying to see that red message saying “invalid” for the signature :slight_smile:

0 Likes

#11

I spent all day trying to fix this, but no luck :fearful:. I’m running gpg 2.2.20 on Windows 10 with SM 2022 (Dev Channel)

0 Likes

#12

I was able to reproduce this with gpg4win and this issue is next on my list. The current workaround is to use the gpg shipped with git for windows instead of gpg4win.

2 Likes

#13

Confirmed fixed in stable build 2025. Thanks! :slight_smile:

2 Likes

#14

Yes, I upgraded from 2020 which had this issue to 2027 and the problem was fixed. Thanks a lot!

0 Likes