git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [ANNOUNCE] Git v2.2.0

From
Jeff King <peff@peff.net>
Date
Nov 28, 2014, 04:46 UTC
Message-ID
<20141128044656.GA19456@peff.net>
In-Reply-To
<20141127213224.GA27443@dispater.uplinklabs.net>
[nit: when quoting in your replies, please trim quotes to a reasonable
 length]
On Thu, Nov 27, 2014 at 01:32:24PM -0800, Steven Noonan wrote:
Show 7 quoted lines
> I'm sad to report that I'm getting test failures with this release.
> Built from git and did 'make -C t prove NO_SVN_TESTS=1' and got this
> result:
> [...]
> I suspect that gnupg v2.1 is to blame somehow (I've had similar bad behavior
> with my own projects using GPG in automation). Running through several of the
> git tests shows that gpg is failing to sign:

I can reproduce here on Debian by installing gnupg2 v2.1 from experimental (this gets installed as /usr/bin/gpg2, so I had to tweak the code to use "gpg2" by default). In my case, gpg2 repeatedly contacts the gpg-agent and pops up X dialogs asking to unlock keyrings in the test suite. Hitting "cancel" causes the tests to fail. Clicking "OK" with an empty passphrase lets the test pass.

The good news is that it is similarly broken on git v2.1.0. So this isn't something we broke; it's the new version of gnupg2.

It's not clear to me whether this is a regression in gnupg, or if there's some magic configuration setting we need to get the old behavior. It seems like the new version is more aggressive in trying to use the agent to get a passphrase, even though the keyrings in the test are unencrypted, and do not need any passphrase. Which sounds like a bug to me.

You might have some luck talking with the gnupg folks about this possible bug. As a simple reproduction, doing:

  cd git/t/lib-gpg
  export GNUPGHOME=$PWD
  echo foo | gpg --sign -a

works fine with gnupg1, or earlier versions of gnupg2. But with gnupg 2.1, it causes the agent to pop up a passphrase dialog.

-Peff
Previous: Steven NoonanNext: Michael J Gruber
Message 3 of 15 in “[ANNOUNCE] Git v2.2.0”
  1. Junio C HamanoNov 26, 2014
  2. Steven NoonanNov 27, 2014
  3. Jeff KingNov 28, 2014
  4. Michael J GruberNov 28, 2014
  5. tests do not work with gpg 2.1Jeff King, Nov 28, 2014
  6. Michael J GruberDec 2, 2014
  7. t/lib-gpg: adjust permissions for gnupg 2.1Michael J Gruber, Dec 2, 2014
  8. Jeff KingDec 2, 2014
  9. Junio C HamanoDec 2, 2014
  10. Jeff KingDec 3, 2014
  11. Junio C HamanoDec 3, 2014
  12. Michael J GruberDec 3, 2014
  13. Junio C HamanoDec 3, 2014
  14. Jeff KingDec 2, 2014
  15. Jeff KingDec 2, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.