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

Misleading warning when email doesn’t match account email #15795

Open
j-f1 opened this issue Dec 16, 2022 · 4 comments
Open

Misleading warning when email doesn’t match account email #15795

j-f1 opened this issue Dec 16, 2022 · 4 comments
Labels
bug Confirmed bugs or reports that are very likely to be bugs priority-3 Bugs that affect small number of users and/or relatively cosmetic in nature

Comments

@j-f1
Copy link
Contributor

j-f1 commented Dec 16, 2022

The problem

When I change the local Git config for a repo to use an email other than my own, I get this warning:

This commit will be misattributed
The email in your global Git config ([redacted]) doesn't match your GitHub account.
You can also choose an email local to this repository from the repository settings.

This is misleading:

  • The email in my global Git config does match my GitHub account.
  • The local email is the one at issue, so it should probably say that?

Release version

3.1.3-beta3 (arm64)

Operating system

macOS 12.6.1 (21G217)

Steps to reproduce the behavior

  1. Make sure your global Git email is set to an email connected to your GitHub account
  2. In a Git repository, set your email to an email associated with a different account
  3. Open GitHub desktop and click on the ⚠️ badge of the avatar

Log files

2022-12-16.desktop.beta.log

Screenshots

No response

Additional context

No response

@davidaucoin7377

This comment was marked as off-topic.

@steveward steveward added bug Confirmed bugs or reports that are very likely to be bugs priority-3 Bugs that affect small number of users and/or relatively cosmetic in nature labels Jan 26, 2023
@steveward
Copy link
Member

Thanks for reporting this @j-f1. I reproduced this behavior as well, and have marked it as a bug to get fixed.

@davidaucoin7377

This comment was marked as spam.

@skyvondave
Copy link

skyvondave commented Mar 5, 2023

I'm getting this same message, and the Learn More link is just confounding me more.

image

The Learn More link: https://docs.github.com/en/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-email-preferences/setting-your-commit-email-address#setting-your-commit-email-address-in-git

I realize this may be a bug, but... what intended situation would the error apply to? It seems like it has no reason to exist at all... the only options on that tab are "Use my global Git config" or "Use a local Git config". If I select the latter, why would I add the same email address as the global one? It seems the warning is about something that legimately will happen that is undesired. The Learn More link is a huge blurb explaining the warning... all of that was accidental?

Now I'm concerned that my commits will actually be wrongly attributed... which is the case? How do we know which logic will happen? I suppose I can only test on my own or clients' repos...

I'd think multiple GitHub accounts would not be an issue, especially considering a lot of people's work is not just on one GitHub account on one computer (and it sounds silly to expect otherwise). I have many clients now, and there's no reason to have different computers with their own GitHub Desktop installs for each client that only allows their own GitHub users (which they create) to work on their projects.

Sure that segregation may be some sort of ideal, but it's not realistic to have some sort of restriction to it. At least it appears GitHub is trying to do that, or just has some bad logic here, or an improper warning.

The app should be able to let me log into multiple GitHub accounts and let me assign repos to those. It can still set a global config user as a default, but also let me change the default, while also having a repo setting to smartly use a local user. I'm honestly surprised none of this appears to have even been thought about much when GitHub Desktop was being built. What blocks are there to a sensible multi-user configuration?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Confirmed bugs or reports that are very likely to be bugs priority-3 Bugs that affect small number of users and/or relatively cosmetic in nature
Projects
None yet
Development

No branches or pull requests

4 participants