gpg: signing error: Input/output error
When I tried to deploy my maven project using the command mvn deploy -DperformRelease=true and I got to the step where I had to enter my GPG passphrase I got the above error. I thought this was because I mistyped the passphrase, but after multiple attempts I kept getting the same error. I then updated my GPG installation to the most recent modern version, but still the same error.
Then I tried to create a new key, but when I got to the step where I had to create the password I got this error:
gpg: agent_genkey failed: Input/output error
Key generation failed: Input/output error
Also an input/output error. Interestingly enough, I believe that in both cases I had this error spit out 2 lines above those errors:
gpg: AllowSetForegroundWindow(16252) failed: Access is denied.
Whether that is related, I don't know. What can I do to resolve this?