Closed
Bug 867346
Opened 11 years ago
Closed 7 years ago
possible to delete the "last" superuser
Categories
(Mozilla QA Graveyard :: MozTrap, defect)
Mozilla QA Graveyard
MozTrap
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: yoshi.yokotani, Unassigned)
References
()
Details
Attachments
(1 file)
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:20.0) Gecko/20100101 Firefox/20.0 Build ID: 20130329030848 Steps to reproduce: in the local version of moztrap (localhost:8000) 1. Manage->Users 2. click the trash-bin icon on the "last" superuser Actual results: the superuser can be deleted. Then, it is not possible to recover the user from moztrap. Expected results: it might be better to prevent the deletion to avoid a work on the django
Reporter | ||
Updated•11 years ago
|
Reporter | ||
Comment 1•11 years ago
|
||
it was found that clicking the deactivate button on the superuser landed on the same issue. So, the title can be rephrased as "possible to delete/deactivate the "last" superuser.".
Comment 2•11 years ago
|
||
Attachment #822140 -
Flags: review?(cdawson)
Comment 3•11 years ago
|
||
Comment on attachment 822140 [details] [review] Patch for this bug I modified the User model a little bit. Now, when deletion/deactivation of a User is triggered, moztrap will check whether the one is the "last" superuser or not.
Comment 4•11 years ago
|
||
Shiro-- this looks very close. I found an edge case. I left a message on github on the PR as follows: @sh1r0 : So I tested this a bit, and it does prevent deactivation when you are in the manage/users list and click the green button and select disable. But for some reason it does NOT prevent this when you edit the user and uncheck the "active" checkbox and save. I think this would require you override the save function and do your check there as well. Perhaps if they ARE the last superuser, allow the save to continue, but silently set active=True. Thanks.
Updated•11 years ago
|
Attachment #822140 -
Flags: review?(cdawson) → review+
Mass-closing remaining MozTrap bugs as WONTFIX, due to 1) the Mozilla-hosted instance being decommissioned (see https://wiki.mozilla.org/TestEngineering/Testrail), and, for now, 2) the still-up code archived at its GitHub page: https://github.com/mozilla/moztrap (we'll decide what's next for that, in the near future). See also the history and more-detailed discussion which led us here, at https://groups.google.com/forum/#!topic/mozilla.dev.quality/Sa75hV8Ywvk (If you'd like, you should be able to filter these notification emails using at least the unique string of "Sa75hV8Ywvk" in the message body. Thanks!
Status: UNCONFIRMED → RESOLVED
Closed: 7 years ago
Resolution: --- → WONTFIX
Updated•6 years ago
|
Product: Mozilla QA → Mozilla QA Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•