Comment 2 for bug 847388

Revision history for this message
Mark Grandi (markgrandi) wrote :

I tried this out by commiting by just using the terminal (since for some reason, invoking bzr explorer says it can't find some import if i run it from the code i checked out from launchpad) and it still works. It also still manages (or bazaar does at least) to print messages if you enter your password wrong. So it does work on the terminal, and when i edited bzrlib/gpg.py in my install on ubuntu and added the --no-tty line, it worked in bazaar explorer too

I think gpg can find the agent fine, its just trying to print SOMETHING to /dev/tty, and when it can't find that it freaks out and then bazaar catches the exception and then says you can't sign it, as i see the pinentry-gtk-2 window when i commit with the changes i made. I will have to check to see if this works with windows and mac as well (with the gpg installations i have on those computers)

Also, My original changes were to only use --no-tty if os.environ("TTY") returned None, however it seems that on Ubuntu at least, os.environ("TTY") always returns none, no matter if you are running bzr through the terminal or through bzr explorer. I thought it would only return None if it was running through a GUI environment, but it appears to not be the case.