Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow authors to use different emails in different PEPs? #3621

Open
hugovk opened this issue Jan 12, 2024 · 7 comments
Open

Allow authors to use different emails in different PEPs? #3621

hugovk opened this issue Jan 12, 2024 · 7 comments
Labels
meta Related to the repo itself and its processes

Comments

@hugovk
Copy link
Member

hugovk commented Jan 12, 2024

Dear fellow @python/pep-editors,

This came up in #3618, the build failed because the PEP author has previously used his personal email address in other PEPs, but his work email in this new PEP:

Is it a hard requirement that authors must use the same email for all PEPs?

Or can we allow authors to use whichever they find most appropriate for each PEP?


Code-wise, we'd need at least need to modify _verify_email_addresses:

  • not to raise if more than one email
  • and in the PEP 0 table of names & emails:
    • print just one email
    • print all emails
    • or even ditch that table altogether

def _verify_email_addresses(peps: list[PEP]) -> dict[str, str]:
authors_dict: dict[str, set[str]] = {}
for pep in peps:
for author in pep.authors:
# If this is the first time we have come across an author, add them.
if author.full_name not in authors_dict:
authors_dict[author.full_name] = set()
# If the new email is an empty string, move on.
if not author.email:
continue
# If the email has not been seen, add it to the list.
authors_dict[author.full_name].add(author.email)
valid_authors_dict: dict[str, str] = {}
too_many_emails: list[tuple[str, set[str]]] = []
for full_name, emails in authors_dict.items():
if len(emails) > 1:
too_many_emails.append((full_name, emails))
else:
valid_authors_dict[full_name] = next(iter(emails), "")
if too_many_emails:
err_output = []
for author, emails in too_many_emails:
err_output.append(" " * 4 + f"{author}: {emails}")
raise ValueError(
"some authors have more than one email address listed:\n"
+ "\n".join(err_output)
)
return valid_authors_dict

@hugovk hugovk added the meta Related to the repo itself and its processes label Jan 12, 2024
@gvanrossum
Copy link
Member

The philosophical issue is what is the email for. Are there two authors who happen to have the same name but are distinguished by email? Or does the email convey a role? Or is it simply a way to reach the author? What should happen if the author changes jobs or retires?

@AA-Turner
Copy link
Member

I'm minded to suggest keeping the email check, as it means that the reader can be confident that the authors are in fact the same person, rather than two people that happen to have the same name. As a by-product it means that if someone updates their email address, it must be updated everywhere, which a reviewer might forget to check.

A

@Julian-Dumitrascu

This comment has been minimized.

@gvanrossum
Copy link
Member

Does this need more deliberation? Or should we just assume that the status quo wins, and there is little appetite for change?

@Mariatta
Copy link
Member

I'd recommend updating the email check logic to allow the same person to have more than one email address in different PEPs. It is normal for anyone to own more than one email address anyway, and it is the author's choice. We can list the author's multiple email addresses on PEP 0. We shouldn't need to update past PEPs with new email address, unless the author wants to do it.

@Julian-Dumitrascu

This comment was marked as off-topic.

@gvanrossum
Copy link
Member

I'd recommend updating the email check logic to allow the same person to have more than one email address in different PEPs. It is normal for anyone to own more than one email address anyway, and it is the author's choice. We can list the author's multiple email addresses on PEP 0. We shouldn't need to update past PEPs with new email address, unless the author wants to do it.

If we were talking about different forums (e.g. two different Discourse servers) I agree users need freedom in which email they use. But given that PEPs are a flat namespace, what purpose is served by allowing multiple email addresses? If someone submits one PEP as a private user and another as an engineer at some company, the most likely outcome to me seems that some years later one or the other email address becomes invalid. This can be annoying when (as has happened) we want to contact a user year later with a question if an ambiguity in a PEP needs to be resolved.

Note that in the issue linked from the top comment here, the affected user writes

Using my personal email here is not a significant problem -- the ToB email would accurately reflect that this is for work rather than just funsies, but we have it tracked on our side anyways 🙂

so I don't think this case is strong enough to change the restriction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
meta Related to the repo itself and its processes
Projects
None yet
Development

No branches or pull requests

5 participants