-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
Users with hidden emails will see a noreply email on their profile #28477
base: main
Are you sure you want to change the base?
Conversation
Gitea, unlike GitLab and GitHub, would show the user's email address on their profile and gave some users something close to a heart attack. This is obviously not healthy, so I built a new feature that would add an icon showing a padlock next to it, to show whether the email would be visible to other users or not. Such an indicator is important, because hiding your email address will mean that a "noreply@..." email address will be used for Git web operations, and this can mess the metadata of a repository if you just don't want your address to be shown on your profile, but still use it for commits. If you're one of those people, it is very likely that you may not want that if you do livestreams, screencasts or just showing your screen to someone else somehow. For that reason, the "noreply" email address will now be shown on the user's profile. This should show people that the noreply address will be used for every single Git-related thing that they do on the platform. It's probably less misleading tihs way, too. Fixes https://codeberg.org/forgejo/forgejo/issues/1950
Hopefully this is good enough to be merged as-is, but I'd like to ask for a more careful check just to be sure. :P I am not sure if the tests are a bit redundant, especially because |
tests/integration/setting_test.go
Outdated
|
||
setting.UI.ShowUserEmail = false | ||
|
||
// user1 can see own (now hidden) email | ||
// user1 can see own noreply email (email hidden) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The current tests below suggest the opposite of this, ie. that user still sees (.Contains
) their own e‐mail (user1@example.com
) and that they don’t see (.NotContains
) their noreply e‐mail (user[12]@noreply.example.org
)… which way is it supposed to be?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK, this is a problem.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Investigating possible logic error when ShowUserEmail is disabled in the config
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if this investigating is still on-going, but the current/new comment still doesn’t seem to match what the tests are testing. (If it’s still being investigated, then disregard this comment!)
Co-authored-by: Frederik “Freso” S. Olesen <177659+Freso@users.noreply.github.com>
Co-authored-by: JakobDev <jakobdev@gmx.de>
Yeah, I see what you mean. Using this project as an avenue to take something that has been already defined by another platform (i.e. GitHub) and trying to "make it better" through experiments may lead to some things that are not executed as well as they were before - I'm generally eager to alter the scope of my PR or throw away some work, given that I have something to work with (thanks for the feedback!), as long as every involved party / "stakeholder" ends up "further than they were yesterday". One subset of the users we're talking about, that being "people sharing their screen when using the software", are experiencing this problem now and I'd find it optimal to fix it as fast as possible. I could implement the "Click to reveal" feature, but I don't think I can implement it fast and right because I'm not an experienced. I would love to implement it later, but it might be best to settle for something fast for now. Here are two ideas:
The logic (and the knowledge of the precise lines I would need to change) would mean that it would not be much work on my end and would get all of us a little bit further than before. What do you think I should do? @techknowlogick |
@n0toose my feelings are leaning towards starting with option 2 (I like your suggestion of keeping the open padlock showing the user that the email is public) and then possibly revisiting this with the "click to show" logic once more research could be done into it (vs doing it quickly and refactoring it as time goes on), as I suspect adding this type of component would add a general pattern that could be used elsewhere, and so more considerations may be needed. This, of course, isn't a blocking comment, just some suggestions on the approach, as really the only thing that I'd be hesitant about is showing the no-reply address. I am of course supportive of a change to the existing behaviour, as the case of leaking private information while screen sharing is definitely something I agree should be addressed :) |
Thanks for the feedback! I will go for that option then (and deliberately leave the string for the private email in). |
@techknowlogick I revisited this PR and spent some time thinking about the way I approached it. I would like to justify my original unorthodox decision of showing the private email address better and ask whether it's a bad idea again. I'd like to try justifying showing the placeholder email to the user, and particularly on the profile, mostly philosophically. deep breath
The reason why I chose to show the hidden email was because the hidden email will be associated with private commits. The private email is the user's assumed identity on the web UI, and it makes sense to me to use the profile to remind that fact instead of just before before they make a commit). The user visits their own profile very often - it serves the function of creating an identity to show other people using your repositories, a bio or a profile README. It also consists of a Public Activity feed; I can put the Public Activity out there and associate it with my identity, or just hide it and use it as an own personal reference of my interactions with an instance ("The instance associates commits and comments with my identity."). It's also a place where I can reach the repositories I host on an instance. The profile is not just a profile - where you get to define how others on the instance see you -, it's also a place shows you what you do on your instance and your "relationship" with it. How you tell an instance to identify you and how your commits will be shown to other people is a part of that relationship. Not sure if that made sense, but I see showing hidden email as similar as showing the Public Activity tab to the user, even if it's not hidden. The latter answers the question of "what commits and comments the instance associates with me", whereas the former says "what email address does the instance associate with me and use for commits".
I'm coming from the perspective of public instances, but in the context of a company, "Do I want the instance to associate me and my commits with a I think that showing this next to the merge button makes sense, but I also think that not showing it earlier is a bit late. |
Gitea, unlike GitLab and GitHub, would show the user's email address on their profile and gave some users something close to a heart attack.
This is obviously not healthy, so I built a new feature that would add an icon showing a padlock next to it, to show whether the email would be visible to other users or not. Such an indicator is important, because hiding your email address will mean that a "noreply@..." email address will be used for Git web operations, and this can mess the metadata of a repository if you just don't want your address to be shown on your profile, but still use it for commits.
If you're one of those people, it is very likely that you may not want that if you do livestreams, screencasts or just showing your screen to someone else somehow.
For that reason, the "noreply" email address will now be shown on the user's profile. This should show people that the noreply address will be used for every single Git-related thing that they do on the platform. It's probably less misleading this way, too.
Fixes https://codeberg.org/forgejo/forgejo/issues/1950