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

Re: [PATCH] submodule: correct error message for missing commits.

From
Junio C Hamano <gitster@pobox.com>
Date
Sep 27, 2017, 00:52 UTC
Message-ID
<xmqqlgl17yjj.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<20170926182756.13319-1-sbeller@google.com>
Stefan Beller <sbeller@google.com> writes:
Show 21 quoted lines
> When a submodule diff should be displayed we currently just add the
> submodule objects to the main object store and then e.g. walk the
> revision graph and create a summary for that submodule.
>
> It is possible that we are missing the submodule either completely or
> partially, which we currently differentiate with different error messages
> depending on whether (1) the whole submodule object store is missing or
> (2) just the needed for this particular diff. (1) is reported as
> "not initialized", and (2) is reported as "commits not present".
>
> If a submodule is deinit'ed its repository data is still around inside
> the superproject, such that the diff can still be produced. In that way
> the error message (1) is misleading as we can have a diff despite the
> submodule being not initialized.
>
> Downgrade the error message (1) to be the same as (2) and just say
> the commits are not present, as that is the true reason why the diff
> cannot be shown.
>
> Signed-off-by: Stefan Beller <sbeller@google.com>
> ---
Sounds good.  Thanks for working on it.
Previous: Jacob Keller
Message 3 of 3 in “submodule: correct error message for missing commits.”
  1. submodule: correct error message for missing commits.Stefan Beller, Sep 26, 2017
  2. Jacob KellerSep 26, 2017
  3. Junio C HamanoSep 27, 2017

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.