The error messages “Import failed: Fatal: can't create directory '/home/username/~/.gnupg': No such file or directory” and "Couldn't generate PGP key" only come for me when trying to import or create a key from LibreOffice Writer Version: 6.0.7.3, Build ID: 1:6.0.7-0ubuntu0.18.04.10 I am using Ubuntu Version: 18.04.4 LTS (Bionic Beaver)
>From LibreOffice: File -> Digital Signatures -> Digital Signatures … Create a new GPG Key ends with: "Couldn't generate PGP key" Import an existing GPG Key ends with: “Import failed: Fatal: can't create directory '/home/username/~/.gnupg': No such file or directory” When started from LibreOffice Writer there is no GPG key available. But I already created one GPG Key that is available when I start from the applications manager. >From the application’s manager. I can easily create and export a new GPG key when I start the application from the Applications manager. And the created GPG keys are visible in the GUI -- You received this bug notification because you are a member of Desktop Packages, which is subscribed to seahorse in Ubuntu. https://bugs.launchpad.net/bugs/1852210 Title: problem importing gpg keys "Fatal: can't create directory '/home/hazrpg/~/.gnupg': No such file or directory Status in seahorse package in Ubuntu: Confirmed Bug description: There is a problem when importing a GPG private key from a backup, the error message says the File or Directory does not exist - and it looks like its because of the way it's trying to access it. Here's the exact error (verbose as its displayed): Import failed: Fatal: can't create directory '/home/hazrpg/~/.gnupg': No such file or directory It looks like its trying to access ~/.gnupg and at the same time trying to put that in the /home/hazrpg/ directory (hazrpg being my username). It should be one or the other, so its probably a simple fix. Steps to reproduce: 1) Open up seahorse. 2) Click on "File" -> "Import...". 3) Select any valid GPG key file (public, private, etc). 4) Verify its valid with the "Data to be imported:" section and then click on "Import". 5) Error message shows in red below the "Data to be imported:" section with the above message. ProblemType: Bug DistroRelease: Ubuntu 18.04 Package: seahorse 3.20.0-5 ProcVersionSignature: Ubuntu 4.15.0-66.75-generic 4.15.18 Uname: Linux 4.15.0-66-generic x86_64 NonfreeKernelModules: nvidia_modeset nvidia ApportVersion: 2.20.9-0ubuntu7.9 Architecture: amd64 CurrentDesktop: ubuntu:GNOME Date: Tue Nov 12 11:38:18 2019 InstallationDate: Installed on 2019-03-05 (252 days ago) InstallationMedia: Ubuntu 18.04.1 LTS "Bionic Beaver" - Release amd64 (20180725) SourcePackage: seahorse UpgradeStatus: No upgrade log present (probably fresh install) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/seahorse/+bug/1852210/+subscriptions -- Mailing list: https://launchpad.net/~desktop-packages Post to : desktop-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~desktop-packages More help : https://help.launchpad.net/ListHelp