Comment 2 for bug 1685547

Revision history for this message
Dmitry Shachnev (mitya57) wrote :

Nevermind. I have asked the upstream developer of python-keyring, and he says that only unicode passwords are supported [1]. Here launchpadlib is trying to save a bytes password, which is a bug. So I am reassigning this to python3-launchpadlib.

Looking at launchpadlib source, the password is automatically generated and then encoded with base64. I am not sure if base64 is still needed (any unicode characters should work; if no, please report a bug and specify the backend used). But in any case, you can easily convert bytes to unicode by using .decode('latin-1') (and then .encode('latin-1') back when reading the password from the keyring).

[1]: https://github.com/jaraco/keyring/issues/275