Colin Watson has proposed merging ~cjwatson/launchpad:py3-sshkeyset-new into 
launchpad:master.

Commit message:
Fix SSHKeySet.new on Python 3

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/+git/launchpad/+merge/395291

We need to pass bytes to Key.fromString.
-- 
Your team Launchpad code reviewers is requested to review the proposed merge of 
~cjwatson/launchpad:py3-sshkeyset-new into launchpad:master.
diff --git a/lib/lp/registry/model/person.py b/lib/lp/registry/model/person.py
index e1406ca..9834a0a 100644
--- a/lib/lp/registry/model/person.py
+++ b/lib/lp/registry/model/person.py
@@ -4131,7 +4131,7 @@ class SSHKeySet:
 
         if check_key:
             try:
-                key = Key.fromString(sshkey)
+                key = Key.fromString(sshkey.encode("UTF-8"))
             except Exception as e:
                 raise SSHKeyAdditionError(key=sshkey, exception=e)
             if kind != key.sshType():
_______________________________________________
Mailing list: https://launchpad.net/~launchpad-reviewers
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~launchpad-reviewers
More help   : https://help.launchpad.net/ListHelp

Reply via email to