Fix/remove user/soft removal
Original PR : https://github.com/codalab/codabench/pull/1718 from @OhMaley
A brief description of the purpose of the changes contained in this PR.
Fixes some small issues seen after deploying the delete user feature.
It should fix the following problem:
- email formatting
- setting is_active to False on user deletion
- hide deleted user on competition participant list + add an option to display them
Related PR
#1691 (original) #1716 (for deployment)
Issues this PR resolves
Reminder on the hand testing checklist
-
Create a new user -
Complete its profile with as much information as possible -
Create an organization -
Create a competition -
Create a Queue -
Add a submission -
Make the competition and the submission public -
Log out and log in with another user -
Take a look at the new user profile -
Log out and log in with the new user's account -
Delete the account using the account view -
Check your email (or the message in the console) -
Click on the given link -
Check that admins received an email with information on the user's deletion -
Check the the deleted user's got a confirmation email -
Try to log in with the deleted user's account. And fail -
Log in as another user -
Check that the competition and submissions of the removed user are still here but without personal data -
Take a look at the removed user's profile and check that no personal information is displayed
Checklist
-
Code review by me -
Hand tested by me -
I'm proud of my work -
Code review by reviewer -
Hand tested by reviewer -
CircleCi tests are passing -
Ready to merge