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

[Buglet] "git show <random-40-hexdigit>" gives an unclear error message

From
Junio C Hamano <gitster@pobox.com>
Date
Mar 11, 2011, 18:28 UTC
Message-ID
<7vzkp1y0jr.fsf@alter.siamese.dyndns.org>
Here is one who wants to tackle potentially a low-hanging fruit.
  $ git cat-file -p 4cd96ce446ab653325a0e47fad73e94c99c57dd2
  error: unable to find 4cd96ce446ab653325a0e47fad73e94c99c57dd2
  fatal: Not a valid object name 4cd96ce446ab653325a0e47fad73e94c99c57dd2

This looks sensible and understandable, even though you could argue that we don't have to say the same thing twice. In the same repository:

  $ git show 4cd96ce446ab653325a0e47fad73e94c99c57dd3
  fatal: bad object 4cd96ce446ab653325a0e47fad73e94c99c57dd3

This is bad, as it sounds as if we found the named object but it is corrupt.

Next: Jakob Pfender
Message 1 of 3 in “[Buglet] "git show <random-40-hexdigit>" gives an unclear error message”
  1. Junio C HamanoMar 11, 2011
  2. revision.c: Clarify error message for missing objectsJakob Pfender, Mar 14, 2011
  3. Junio C HamanoMar 14, 2011

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.