From: Jonathan Tan Date: Tue, 15 Feb 2022 22:03:41 GMT Subject: Re: [PATCH v2 8/9] submodule: read shallows when finding changed submodules Message-ID: <20220215220341.1634185-1-jonathantanmy@google.com> In-Reply-To: <20220215172318.73533-9-chooglen@google.com> Glen Choo writes: > @@ -901,6 +902,9 @@ static void collect_changed_submodules(struct repository *r, > > save_warning = warn_on_object_refname_ambiguity; > warn_on_object_refname_ambiguity = 0; > + /* make sure shallows are read */ > + is_repository_shallow(the_repository); This is presumably to initialize the data structures that some later code reads without first calling is_repository_shallow(). Do we know which part of the later code this is? If yes, it would be better to fix it there.