Re: [PATCH] trailers: stop recognizing URLs as trailers

"Kristoffer Haugsbakk" <[email protected]>
Newsgroups org.kernel.vger.git
Message-ID <[email protected]>
On Thu, Aug 20, 2026, at 16:38, Junio C Hamano wrote:
> [email protected] writes:
>
>> From: Kristoffer Haugsbakk <[email protected]>
>>
>> An HTTPS URL starts with an alphanumeric scheme followed by a colon.
>> That means that they will be recognized as trailers in a trailer block.
>> That turns out to be a problem in practice. Let’s stop recognizing these
>> as trailers by failing the trailer parsing when we:
>> ...
>> Helped-by: Jeff King <[email protected]>
>> Signed-off-by: Kristoffer Haugsbakk <[email protected]>
>
> This has been on hold waiting for the base topic to settle, but now
> that the base topic has graduated, the effort can be rebooted.

Thanks!

> Can somebody summarize the outstanding issues on this topic (if
> any)?

I have version 2 ready. The only code change is using `starts_with` like
Peff mentioned. What I wrote about the changes:

    • Use `starts_with` for readability:
        https://lore.kernel.org/git/[email protected]/T/#m74203c474c34f1028a7e3d389ff46fb7e579444c
    • Explain in the commit message that you can technically get false positive
      “URL” start fragments:

          https://lore.kernel.org/git/[email protected]/T/#m35047d5c7a79abd23c11f97e6b6a0364409805e3

I just have to dust it off.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.