<div dir="ltr"><div dir="ltr">Hi All,<div><br></div><div>I'm trying to use the "keytocard" functionality in the GPGME python bindings using the "interact" function. However, I can't figure out how to get the callback to work. My callback does indeed get called, but how do I return my response? Returning my response to the prompt as a string e.g "fpr"  or "key 1" or "keytocard" simply causes my whole script to hang. Am I doing something wrong? You can view the code and output here: <a href="https://pastebin.com/8BzTX5Y9" target="_blank">https://pastebin.com/8BzTX5Y9</a> . It seems like the script just hangs after returning from the callback the second time...</div><div><br></div><div>I'm basically following this structure: <a href="https://github.com/gpg/gpgme/blob/b182838f71d8349d6cd7be9ecfb859b893d09127/lang/python/tests/t-edit.py" target="_blank">https://github.com/gpg/gpgme/blob/b182838f71d8349d6cd7be9ecfb859b893d09127/lang/python/tests/t-edit.py</a></div><div><br></div><div>Any help much appreciated :)</div></div></div>