Consider the following command (see Ubuntu bug #190294):
gpg --quiet --no-use-agent --sign --passphrase XXX -u "YYY" --output SIG FILE
You need a passphrase to unlock the secret key for user: "YYY"
IMO --quiet should suppress this message here (if the passphrase is correct). I
then tried to add the --no-tty switch and found, that this will fail with:
gpg: Sorry, no terminal at all requested - can't get input
Is this intended (the passphrase is given)? Further adding --batch makes the
command work. So I'm not sure, if this is really a bug.