GitHub user jl141 added a comment to the discussion: cannot delete user
"Associated data exists, please delete them first"
Hi! @rusackas @mistercrunch @dpgaspar @michael-s-molina @villebro
We have a solution proposal as follows and would greatly appreciate feedback
about our approach:
- Add a new boolean column `DELETED` in table `ab_user`
- Only admins can delete users; during this process (if there are dependencies
preventing the deletion) they will be given the option to either (1) reassign
the user’s associated data to another user (or themselves), or (2) orphan the
associated data so that permalinks still work
- Deletion confirmation e.g. "You will be deleting user {username}. Type DELETE
to continue"
- Modify the appropriate database entries:
- For (1), we would modify relevant entries with the deleted user’s ID to be
the reassigned user’s ID (i.e. dashboards, slices)
- For both, we would modify the column `DELETED` of the table `ab_user` to be
`TRUE`.
- The deleted user will no longer be able to log in or perform any actions. We
can achieve this by setting is_active to `FALSE`
- The deleted user’s username “X” will instead be updated to “[DELETED]_X”, for
the purpose of logs, permalinked dashboards, or account recreation under the
same username. A similar modification will be done to the user’s email field.
- Future queries in the Superset app will filter out rows where the user ID
corresponds to a deleted user. Thus a deleted user’s dashboards and charts will
only be accessible through permalinks, unless they have been reassigned.
GitHub link:
https://github.com/apache/superset/discussions/40137#discussioncomment-16924835
----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]