From: Pablo Sabater Date: Wed, 30 Sep 2026 18:03:26 GMT Subject: Re: [PATCH RFC 3/5] fetch-object-info: return a status instead of dying Message-ID: In-Reply-To: On Wed Sep 30, 2026 at 6:07 PM WEST, Junio C Hamano wrote: > Pablo Sabater writes: > >> A subsequent commit needs fetch_object_info() not to die() when the >> object-info capability is not enabled on the server, so that it can >> fall back. >> >> Make fetch_object_info() return FETCH_OBJECT_INFO_NOT_ENABLED instead >> of die()'ing when the server does not advertise the object-info >> capability, and propagate the status through the transport layer so >> that callers of transport_fetch_object_info() can act on it. It is now >> up to them whether to die() or fall back. > > It may be just me but unless the client can tell between the server > not supporting (i.e., they are unable to enable it even if they > wanted to) and not enabling (i.e., they are capable, but are not > willing to give it to you), it may make sense to report it as "not > available". "not enabled" sounds as if we know that it is the > latter and not the former. > > The code change looks very cleanly done. Makes sense, I'll rename it to FETCH_OBJECT_INFO_NOT_AVAILABLE. The git cat-file remote-object-info command path die()'d with this message: die(_("object-info capability is not enabled on the server")); I'll update the die() message as well. Thanks.