AUTHORS file and .mailmap

37 views
Skip to first unread message

Oscar Benjamin

unread,
Jan 24, 2022, 6:25:51 PM1/24/22
to sympy
Hi all,

I've just merged https://github.com/sympy/sympy/pull/22754

This means that new contributors are required to add themselves to the
.mailmap file before their PR can be merged. It also means that if
someone adds multiple commits with different git date for author and
email then they need to edit the .mailmap file to resolve the
ambiguity about who is the author of the work. There are more detailed
instructions here:
https://github.com/sympy/sympy/wiki/Development-workflow#add-your-name-and-email-address-to-the-mailmap-file

Resolving author metadata has been one of the most awkward aspects of
the release process and is something that can not be automated. From
now on all authors must specify what name should be recorded for their
contributions.

The process now is that all authors should be included in the .mailmap
file. The AUTHORS file will be updated at release time. The .mailmap
file will be kept in alphabetical order but the AUTHORS file will
still be in chronological order. This avoids the merge conflict
problems that my previous attempt had:
https://groups.google.com/g/sympy/c/3DXOKgoeX24/m/xL91f6KTAgAJ

There may be teething problems with the new script but we can improve
it over time.

Oscar

Chris Smith

unread,
Jan 25, 2022, 3:39:16 PM1/25/22
to sympy
Nice step forward, Oscsar. Thanks!

/c

Jeremy Monat

unread,
Jan 25, 2022, 5:20:46 PM1/25/22
to sy...@googlegroups.com
Thanks, Oscar. What do existing contributors need to do?

On Jan 25, 2022, at 3:39 PM, Chris Smith <smi...@gmail.com> wrote:

Nice step forward, Oscsar. Thanks!
--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/c9034dfb-d19f-4410-b055-cb5d5e5a2328n%40googlegroups.com.

Oscar Benjamin

unread,
Jan 25, 2022, 5:28:02 PM1/25/22
to sympy
On Tue, 25 Jan 2022 at 22:20, Jeremy Monat <jem...@gmail.com> wrote:
>
> Thanks, Oscar. What do existing contributors need to do?

Nothing if the name is already recorded in .mailmap:
https://github.com/sympy/sympy/blob/b9b33b424f63727f57e5277bfc6fc8a6619d0cdf/.mailmap#L546
https://github.com/sympy/sympy/blob/b9b33b424f63727f57e5277bfc6fc8a6619d0cdf/AUTHORS#L1130

If any existing contributors can see duplicate names for themselves
either in .mailmap or AUTHORS then they should say so and I'll resolve
it:

I already added every name to .mailmap that wasn't there yet. New
contributors will need to add themselves to .mailmap before their
first PR can be merged though.

--
Oscar

36 AI Kuldeep Borkar

unread,
Jan 30, 2022, 10:26:33 AM1/30/22
to sy...@googlegroups.com
Thank you for your mail Sir Oscar Benjamin,
As a new contributor I was having difficulty after making a pull request authors check failed but then after observing the details I have done these things

--> Before editing .mailmap, I run the command bin/mailmap_update.py
--> then made entry to .mailmap as 
Name <global git email> 
--> then re-run bin/mailmap_update.py
-->  run bin/authors_update.py
--> git commit -am 'Update .mailmap/AUTHORS. Welcome to Sympy!'

Are these things correct?
And will that check pass afterwards or I will have to make the pull request again?

--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.

Oscar Benjamin

unread,
Jan 30, 2022, 1:48:24 PM1/30/22
to sympy
On Sun, 30 Jan 2022 at 15:26, 36 AI Kuldeep Borkar
<kuldeepbo...@gmail.com> wrote:
>
> Thank you for your mail Sir Oscar Benjamin,
> As a new contributor I was having difficulty after making a pull request authors check failed but then after observing the details I have done these things
>
> --> Before editing .mailmap, I run the command bin/mailmap_update.py
> --> then made entry to .mailmap as
> Name <global git email>
> --> then re-run bin/mailmap_update.py
> --> run bin/authors_update.py
> --> git commit -am 'Update .mailmap/AUTHORS. Welcome to Sympy!'
>
> Are these things correct?
> And will that check pass afterwards or I will have to make the pull request again?

No, you should be using mailmap_check.py as described here:
https://github.com/sympy/sympy/wiki/Development-workflow#add-your-name-and-email-address-to-the-mailmap-file

Don't use the mailmap_update.py script: that's the old script that
shouldn't be used any more.

It should be fine to push the changes to your PR. What is potentially
a problem is if your PR was created before the mailmap_check.py script
was added. In that case you'll need to merge or rebase with master
first.

--
Oscar

Aaron Meurer

unread,
Jan 30, 2022, 8:13:54 PM1/30/22
to sy...@googlegroups.com
On Sun, Jan 30, 2022 at 11:48 AM Oscar Benjamin <oscar.j....@gmail.com> wrote:
On Sun, 30 Jan 2022 at 15:26, 36 AI Kuldeep Borkar
<kuldeepbo...@gmail.com> wrote:
>
> Thank you for your mail Sir Oscar Benjamin,
> As a new contributor I was having difficulty after making a pull request authors check failed but then after observing the details I have done these things
>
> --> Before editing .mailmap, I run the command bin/mailmap_update.py
> --> then made entry to .mailmap as
> Name <global git email>
> --> then re-run bin/mailmap_update.py
> -->  run bin/authors_update.py
> --> git commit -am 'Update .mailmap/AUTHORS. Welcome to Sympy!'
>
> Are these things correct?
> And will that check pass afterwards or I will have to make the pull request again?

No, you should be using mailmap_check.py as described here:
https://github.com/sympy/sympy/wiki/Development-workflow#add-your-name-and-email-address-to-the-mailmap-file

Don't use the mailmap_update.py script: that's the old script that
shouldn't be used any more.

I think I mentioned this on the PR, but we should delete those other scripts so they don't confuse people. Or if they are still used by the release scripts they should be moved into the release folder. 

Aaron Meurer 



It should be fine to push the changes to your PR. What is potentially
a problem is if your PR was created before the mailmap_check.py script
was added. In that case you'll need to merge or rebase with master
first.

--
Oscar

--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.

Oscar Benjamin

unread,
Jan 30, 2022, 8:44:13 PM1/30/22
to sympy
On Mon, 31 Jan 2022 at 01:13, Aaron Meurer <asme...@gmail.com> wrote:
>
>
>
> On Sun, Jan 30, 2022 at 11:48 AM Oscar Benjamin <oscar.j....@gmail.com> wrote:
>>
>> On Sun, 30 Jan 2022 at 15:26, 36 AI Kuldeep Borkar
>> <kuldeepbo...@gmail.com> wrote:
>> >
>> > Thank you for your mail Sir Oscar Benjamin,
>> > As a new contributor I was having difficulty after making a pull request authors check failed but then after observing the details I have done these things
>> >
>> > --> Before editing .mailmap, I run the command bin/mailmap_update.py
>> > --> then made entry to .mailmap as
>> > Name <global git email>
>> > --> then re-run bin/mailmap_update.py
>> > --> run bin/authors_update.py
>> > --> git commit -am 'Update .mailmap/AUTHORS. Welcome to Sympy!'
>> >
>> > Are these things correct?
>> > And will that check pass afterwards or I will have to make the pull request again?
>>
>> No, you should be using mailmap_check.py as described here:
>> https://github.com/sympy/sympy/wiki/Development-workflow#add-your-name-and-email-address-to-the-mailmap-file
>>
>> Don't use the mailmap_update.py script: that's the old script that
>> shouldn't be used any more.
>
>
> I think I mentioned this on the PR, but we should delete those other scripts so they don't confuse people. Or if they are still used by the release scripts they should be moved into the release folder.

Yes, we should delete them. We're still in a confusing situation right
now though where different people have different files. If we did
delete the old files then it's likely that Kuldeep would still see
them on this branch. Until the branch is updated it will still show
the old files and not the new. I think a lot of the confusion comes
from that.

--
Oscar

36 AI Kuldeep Borkar

unread,
Jan 31, 2022, 11:51:23 PM1/31/22
to sy...@googlegroups.com
  Thank you for the response and help Sir Oscar Benjamin and Sir Aaron Meurer 
I used the command  mailmap_check.py and my name was there in the .mailmap but
my github user name and email was recorded in the format 1785690...@users.noreply.github.com
therefore, I added the line in .mailmap as mentioned in the format Joe Bloggs <j...@bloggs.com> joeb <1785690...@users.noreply.github.com>
and then I used the following commands
--> $ git add .mailmap
--> $ git commit -m 'author: add Kuldeep to .mailmap'
As you said ''What is potentially
a problem is if your PR was created before the mailmap_check.py script
was added. In that case you'll need to merge or rebase with master
first.''
And unfortunately that was the problem, then I tried to rebase with master, I tried again and again but it was too problematic for me ; )
Then I just closed that PR and deleted the branch then,
I started again with a new branch and made the PR but it showed the changes of the .mailmap file too and then again the author's check failed again.
I guess I am missing some step or I made some mistake though.
Please Help!


--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.

Oscar Benjamin

unread,
Feb 1, 2022, 4:45:44 AM2/1/22
to sympy
On Tue, 1 Feb 2022 at 04:51, 36 AI Kuldeep Borkar
<kuldeepbo...@gmail.com> wrote:
>
> Thank you for the response and help Sir Oscar Benjamin and Sir Aaron Meurer
> I used the command mailmap_check.py and my name was there in the .mailmap but
> my github user name and email was recorded in the format 1785690...@users.noreply.github.com
> therefore, I added the line in .mailmap as mentioned in the format Joe Bloggs <j...@bloggs.com> joeb <1785690...@users.noreply.github.com>
> and then I used the following commands
> --> $ git add .mailmap
> --> $ git commit -m 'author: add Kuldeep to .mailmap'
> As you said ''What is potentially
> a problem is if your PR was created before the mailmap_check.py script
> was added. In that case you'll need to merge or rebase with master
> first.''
> And unfortunately that was the problem, then I tried to rebase with master, I tried again and again but it was too problematic for me ; )
> Then I just closed that PR and deleted the branch then,
> I started again with a new branch and made the PR but it showed the changes of the .mailmap file too and then again the author's check failed again.
> I guess I am missing some step or I made some mistake though.
> Please Help!

The error message says:

This author is not included in the .mailmap file:
Kuldeep Borkar Jr <74557588+Ku...@users.noreply.github.com>

That doesn't match the name that you added to .mailmap which is

Kuldeep <74557588+Ku...@users.noreply.github.com>

--
Oscar

36 AI Kuldeep Borkar

unread,
Feb 1, 2022, 6:09:32 AM2/1/22
to sy...@googlegroups.com
Thank You So Much Sir Oscar Benjamin😄  
Finally, it worked like a charm and now I will try my best to start making some good contributions towards my open source journey .

--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages