Re: [docs] [PATCH] contributor-guide: recommend format.forceInBodyFrom

Tim Orling
2024-05-02T20:23:11Z

[-- Attachment #1: Type: text/plain, Size: 4864 bytes --]

On Thu, May 2, 2024 at 1:16 PM Alexander Kanavin <alex.kanavin@gmail.com>
wrote:

> I have to agree with Alexandre: forceInBodyFrom is not necessary. My
> setup for poky is:
>
> [user]
> email = alex@linutronix.de
> name = Alexander Kanavin
> [sendemail]
> smtpEncryption = tls
> smtpServer = smtp.gmail.com
> smtpUser = alex.kanavin@gmail.com
> smtpServerPort = 587
>
> from = Alexander Kanavin <alex.kanavin@gmail.com>
> to = openembedded-core@lists.openembedded.org
>
>
> So patches are made with the linutronix identity, but emails are made
> with gmail identity, and then git send-email adds the extra From: into
> the email body automatically. No need to force stuff.
>
> You guys need to double check your setup, I think.
>

The reason for this thread was a comment from RP during the YP Bug Triage
meeting that things were different recently, so we are trying to make sure
we get this correct.
Either something changed in groups.io or somewhere else, because my setup
only added either of these settings today.
I have just sent three emails with the same exact patch but different
settings to test-list
(1) both sendemail.from and format.forceInBodyFrom
(2) only sendemail.from
(3) neither sendemail.from nor format.forceInBodyFrom

#3 is also the same conditions I used to send the original patch to the
oe-core list.

I would have expected to have heard from Alexandre Belloni previously that
there was an issue with my setup in #3.

>
> Alex
>
>
> On Thu, 2 May 2024 at 21:45, Alexandre Belloni via
> lists.yoctoproject.org
> <alexandre.belloni=bootlin.com@lists.yoctoproject.org> wrote:
> >
> > On 02/05/2024 13:25:54-0600, Joshua Watt wrote:
> > > On Thu, May 2, 2024 at 1:18 PM Alexandre Belloni via
> > > lists.yoctoproject.org
> > > <alexandre.belloni=bootlin.com@lists.yoctoproject.org> wrote:
> > > >
> > > > On 02/05/2024 08:27:02-0700, Tim Orling wrote:
> > > > > We are seeing a lot of patches failing when the From:
> > > > > line is not contained in the message body. It is probably
> > > > > better to just recommend to force the in-body From: to be
> > > > > present globally.
> > > > >
> > > > > Signed-off-by: Tim Orling <tim.orling@konsulko.com>
> > > > > ---
> > > > > documentation/contributor-guide/submit-changes.rst | 5 +++++
> > > > > 1 file changed, 5 insertions(+)
> > > > >
> > > > > diff --git a/documentation/contributor-guide/submit-changes.rst
> b/documentation/contributor-guide/submit-changes.rst
> > > > > index 47a416b24..c292a143a 100644
> > > > > --- a/documentation/contributor-guide/submit-changes.rst
> > > > > +++ b/documentation/contributor-guide/submit-changes.rst
> > > > > @@ -65,6 +65,11 @@ use to identify your commits::
> > > > > git config --global user.name "Ada Lovelace"
> > > > > git config --global user.email "ada.lovelace@gmail.com"
> > > > >
> > > > > +To ensure that your patches are formatted properly, it is also
> > > > > +recommended to set::
> > > > > +
> > > > > + git config --global format.forceInBodyFrom true
> > > > > +
> > > >
> > > > I do believe the current documentation already points to a working
> > > > solution:
> > > >
> > > >
> https://docs.yoctoproject.org/contributor-guide/submit-changes.html#fixing-your-from-identity
> > > >
> > > > Doesn't that work for you?
> > >
> > > Empirically, that is insufficient. I've had that set and it mangled my
> > > From line anyway. I beleive that only affects the SMTP header From,
> > > when you actually need the "correct" From in the message body as a Git
> > > header (which is what format.forceInBodyFrom does). Besides, most
> > > people probably already set that anyway because I think it prompts if
> > > you don't have it set
> >
> > I'm pretty sure this has ensured the From: was in the body for us at
> > Bootlin.
> >
> > >
> > > >
> > > > > Clone the Git repository for the component to modify
> > > > > ----------------------------------------------------
> > > > >
> > > > > --
> > > > > 2.43.2
> > > > >
> > > > >
> > > >
> > > > --
> > > > Alexandre Belloni, co-owner and COO, Bootlin
> > > > Embedded Linux and Kernel engineering
> > > > https://bootlin.com
> > > >
> > > >
> > > >
> >
> > --
> > Alexandre Belloni, co-owner and COO, Bootlin
> > Embedded Linux and Kernel engineering
> > https://bootlin.com
> >
> > -=-=-=-=-=-=-=-=-=-=-=-
> > Links: You receive all messages sent to this group.
> > View/Reply Online (#5207):
> https://lists.yoctoproject.org/g/docs/message/5207
> > Mute This Topic: https://lists.yoctoproject.org/mt/105864996/1686489
> > Group Owner: docs+owner@lists.yoctoproject.org
> > Unsubscribe: https://lists.yoctoproject.org/g/docs/unsub [
> alex.kanavin@gmail.com]
> > -=-=-=-=-=-=-=-=-=-=-=-
> >
>

[-- Attachment #2: Type: text/html, Size: 7919 bytes --]