Right now, while saving the password to the keyring works perfectly (when "Remember Password" is picked), loading from the keyring fails.
There's 2 issues at hand here:
gi.Secret.Service doesn't work async on python for some reason. The _final never fires. I could replicate this issue on a variety of distributions. So to fix this, I moved those functions to the relevant sync methods. While this isn't ideal, it fixes the bug at hand. gi.Secret.PasswordStore does seem to work.
The .secret and .attribute functions of Secret.Item objects give out gi.overrides.Gio._DBusProxyMethodCall objects, not the actual contents. I ended up using .get_secret().get() (returns bytes) and .get_attributes()["user"] (returns str). I feel like the change on user especially was important, as the last one involved a for loop through the entire array.
This PR fixes both of them. Tested and confirmed working.
Right now, while saving the password to the keyring works perfectly (when "Remember Password" is picked), loading from the keyring fails.
There's 2 issues at hand here:
gi.Secret.Service
doesn't work async on python for some reason. The _final never fires. I could replicate this issue on a variety of distributions. So to fix this, I moved those functions to the relevant sync methods. While this isn't ideal, it fixes the bug at hand.gi.Secret.PasswordStore
does seem to work.gi.overrides.Gio._DBusProxyMethodCall
objects, not the actual contents. I ended up using.get_secret().get()
(returnsbytes
) and.get_attributes()["user"]
(returnsstr
). I feel like the change on user especially was important, as the last one involved a for loop through the entire array.This PR fixes both of them. Tested and confirmed working.