{"action":"created","issue":{"url":"https://api.github.com/repos/isislovecruft/python-gnupg/issues/107","repository_url":"https://api.github.com/repos/isislovecruft/python-gnupg","labels_url":"https://api.github.com/repos/isislovecruft/python-gnupg/issues/107/labels{/name}","comments_url":"https://api.github.com/repos/isislovecruft/python-gnupg/issues/107/comments","events_url":"https://api.github.com/repos/isislovecruft/python-gnupg/issues/107/events","html_url":"https://github.com/isislovecruft/python-gnupg/issues/107","id":75214045,"number":107,"title":"Inconsistent behaviour for gnupghome","user":{"login":"slafs","id":210173,"avatar_url":"https://avatars.githubusercontent.com/u/210173?v=3","gravatar_id":"","url":"https://api.github.com/users/slafs","html_url":"https://github.com/slafs","followers_url":"https://api.github.com/users/slafs/followers","following_url":"https://api.github.com/users/slafs/following{/other_user}","gists_url":"https://api.github.com/users/slafs/gists{/gist_id}","starred_url":"https://api.github.com/users/slafs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/slafs/subscriptions","organizations_url":"https://api.github.com/users/slafs/orgs","repos_url":"https://api.github.com/users/slafs/repos","events_url":"https://api.github.com/users/slafs/events{/privacy}","received_events_url":"https://api.github.com/users/slafs/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-05-11T13:01:07Z","updated_at":"2016-04-10T11:18:35Z","closed_at":"2016-04-10T10:42:30Z","body":"When instantiating GPG class from some directory, say ``/tmp`` (other than HOME dir), like this\r\n\r\n    gpg = gnupg.GPG(gnupghome='~/.gnupg')\r\n\r\nthose two directories are created inside ``/tmp`` dir, like so:\r\n\r\n    /tmp/~/.gnupg\r\n\r\nbut if I use that ``gpg`` object (e.g. ``gpg.decrypt(text)``), then the path for homedir gets expanded and the library uses my gnupg home directory (i.e. ``$HOME/.gnupg``).\r\n\r\nDocumentation says that ``gnupghome`` shouldn't contain any special characters but I guess ``~`` could be expanded while instantiating the class as a special case scenario (I also assume treating ``~`` as a regular character, while working with the library, can't be done easily).\r\n"},"comment":{"url":"https://api.github.com/repos/isislovecruft/python-gnupg/issues/comments/207963980","html_url":"https://github.com/isislovecruft/python-gnupg/issues/107#issuecomment-207963980","issue_url":"https://api.github.com/repos/isislovecruft/python-gnupg/issues/107","id":207963980,"user":{"login":"kerstin","id":559572,"avatar_url":"https://avatars.githubusercontent.com/u/559572?v=3","gravatar_id":"","url":"https://api.github.com/users/kerstin","html_url":"https://github.com/kerstin","followers_url":"https://api.github.com/users/kerstin/followers","following_url":"https://api.github.com/users/kerstin/following{/other_user}","gists_url":"https://api.github.com/users/kerstin/gists{/gist_id}","starred_url":"https://api.github.com/users/kerstin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kerstin/subscriptions","organizations_url":"https://api.github.com/users/kerstin/orgs","repos_url":"https://api.github.com/users/kerstin/repos","events_url":"https://api.github.com/users/kerstin/events{/privacy}","received_events_url":"https://api.github.com/users/kerstin/received_events","type":"User","site_admin":false},"created_at":"2016-04-10T11:18:35Z","updated_at":"2016-04-10T11:18:35Z","body":"PS: I was originally interested in your question because I misunderstood the usage of homedir/gnuhome in both libraries (see #146).\r\n\r\nI'm also using the original `python-gnupg` now though because I unfortunately can't get `gnupg` to work on Linux... (#145)"}}