From: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
To: Derrick Stolee <derrickstolee@github.com>
Cc: Derrick Stolee via GitGitGadget <gitgitgadget@gmail.com>,
git@vger.kernel.org, peff@peff.net, vdye@github.com,
gitster@pobox.com
Subject: Re: [PATCH 1/3] bundle-uri: drop unused 'uri' parameter
Date: Tue, 20 Dec 2022 21:46:21 +0100 [thread overview]
Message-ID: <221220.86k02lx0l7.gmgdl@evledraar.gmail.com> (raw)
In-Reply-To: <75107325-bd28-1adf-b260-ba8846c63229@github.com>
On Tue, Dec 20 2022, Derrick Stolee wrote:
> On 12/19/22 5:57 AM, Ævar Arnfjörð Bjarmason wrote:
>> On Mon, Dec 12 2022, Derrick Stolee via GitGitGadget wrote:
>
>>> @@ -112,10 +112,10 @@ int fetch_bundle_uri(struct repository *r, const char *uri);
>>> * bundle-uri protocol v2 verb) at the given uri, fetch and unbundle the
>>> * bundles according to the bundle strategy of that list.
>>> *
>>> - * Returns non-zero if no bundle information is found at the given 'uri'.
>>> + * It is expected that the given 'list' is initialized, including its
>>> + * 'baseURI' value
>
>> The same goes for the added docs, that we "expect [that] 'list' is
>> initialized" may be true, but that would have been true before we
>> removed this unused parameter, so let's not stick that in this unrelated
>> "UNUSED" change.
>
> It is _not_ unrelated. The 'uri' parameter looks like it should
> be used to determine relative URLs for the included list. However,
> this reasoning around the 'baseURI' value points out that we are
> using that value _instead_ of the 'uri' value, which is why it
> is safe to remove the parameter.
I'm saying that the function expected that baseURI to be initialized
before, but with your rationale I think it's fine to also do it in one
commit.
I also pointed out (and you elided) that we should still document the
return code, do you agree that we should keep that?
next prev parent reply other threads:[~2022-12-20 20:49 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-12 17:33 [PATCH 0/3] Bundle URIs 4.5: fixups from part IV Derrick Stolee via GitGitGadget
2022-12-12 17:33 ` [PATCH 1/3] bundle-uri: drop unused 'uri' parameter Derrick Stolee via GitGitGadget
2022-12-19 10:57 ` Ævar Arnfjörð Bjarmason
2022-12-20 0:49 ` Junio C Hamano
2022-12-20 14:02 ` Derrick Stolee
2022-12-20 20:50 ` Ævar Arnfjörð Bjarmason
2022-12-20 13:57 ` Derrick Stolee
2022-12-20 20:46 ` Ævar Arnfjörð Bjarmason [this message]
2022-12-12 17:33 ` [PATCH 2/3] bundle-uri: advertise based on repo config Derrick Stolee via GitGitGadget
2022-12-19 11:04 ` Ævar Arnfjörð Bjarmason
2022-12-20 13:54 ` Derrick Stolee
2022-12-12 17:33 ` [PATCH 3/3] bundle-uri: remove GIT_TEST_BUNDLE_URI env variable Derrick Stolee via GitGitGadget
2022-12-19 11:09 ` Ævar Arnfjörð Bjarmason
2022-12-20 13:51 ` Derrick Stolee
2022-12-20 20:41 ` Ævar Arnfjörð Bjarmason
2022-12-12 18:07 ` [PATCH 0/3] Bundle URIs 4.5: fixups from part IV Victoria Dye
2022-12-12 20:59 ` Jeff King
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=221220.86k02lx0l7.gmgdl@evledraar.gmail.com \
--to=avarab@gmail.com \
--cc=derrickstolee@github.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=gitster@pobox.com \
--cc=peff@peff.net \
--cc=vdye@github.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).