From: Junio C Hamano Date: Mon, 28 Apr 2025 21:50:10 GMT Subject: Re: [PATCH v2 08/13] builtin/show-ref: don't fetch objects when printing refs Message-ID: In-Reply-To: <20250425-pks-object-store-cleanups-v2-8-63f1695b7700@pks.im> Patrick Steinhardt writes: > When printing references via git-show-ref(1) we double check that their > respective object IDs point to an existing object. This check is > performed via `repo_has_object_file()`, which knows to fetch missing > promised objects in the background. We shouldn't have a need to fetch > such objects though as no reference should ever point to a missing > object at all. But hasn't the earlier part of this series made sure that asking has_object() without an extra flag would make it say "no" if the object that we know we can obtain is kept in our promisor remote to be lazily fetched? Or am I missing some other mechanism to make sure that somebody does any necessary lazy fetching of an object before we point our refs at it? Thanks.