-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
500 internal server error when renaming an organisation as reserved name #17876
Comments
Has you try the new version (v1.15.6) ? |
fix go-gitea#17876 Signed-off-by: a1012112796 <1012112796@qq.com>
fix #17876 Signed-off-by: a1012112796 <1012112796@qq.com>
Yep, 1.15.6 shows the same error, but I see you have added a patch. |
fix go-gitea#17876 Signed-off-by: a1012112796 <1012112796@qq.com>
just checked: 1.15.7 no longer crashes, just shows 'illegal_username' in a red dialog box. |
|
fix go-gitea#17876 Signed-off-by: a1012112796 <1012112796@qq.com>
Gitea Version
1.15.3
Git Version
No response
Operating System
No response
How are you running Gitea?
standalone binary installation gitea-1.15.3-linux-arm-6 image installed under a dedicated "gitea" user
Database
SQLite
Can you reproduce the bug on the Gitea demo site?
No
Log Gist
No response
Description
When I tried to rename one of my organisations to "admin" (for my git repo's with administrative scripts etc) I got a nondescript "500" error (without "internal server error" or any other information).
Being my own gitea admin, I was able to find the log entry:
2021/12/01 21:04:40 ...s/web/org/setting.go:72:SettingsPost() [E] ChangeUserName: name is reserved [name: admin]
It would be much more user friendly if at least this error message was displayed in the UI.
As far as I can tell this is being triggered via CreateOrgnization() when it gets an error from user_model.IsUsableUsername()
Also, the list of reserved names in models/user/user.go (reservedUsernames var) would be useful information to help the user understand what went wrong.
Screenshots
No response
The text was updated successfully, but these errors were encountered: