Hi there! There have been a lot of problems/discussions when it comes to Drupal's handling of deleted user accounts. The problems did arise from the fact that we did leave user information in some places (notably node authorship, etc). The discussions did arise from the fact whether we should keep the content or not. I did propose to fix the problems (http://drupal.org/node/53348#comment-82298) and retain the content. it would be easy to do a contrib module which would delete the content instead (just make sure your user hook gets called befor the one in node.module). I think this approach is least destructive and leaves opportunities for other approaches. Jose and Zen did provide a patch (http://drupal.org/files/issues/user_delete_3_0.patch) which I will be glad to commit if I get otld it works by an independend review. If you disagree with this approach and thinks it does not allow you to do something you think that Drupal should allow you to do, please let me know too. But you better be quick about it. :p Cheers, Gerhard
This seems to make everything deleted to belong to anonymous. At that point they are all indistinguishable, i.e. you can't tell which ones were spammers and really should disapear entirely. So a very aggressive delete spammers should be done first. Someone needs to write the delete spammer module as a prerequisite to applying this patch.
-----Original Message----- From: development-bounces@drupal.org [mailto:development-bounces@drupal.org] On Behalf Of Gerhard Killesreiter Sent: Sunday, March 26, 2006 1:07 PM To: development@drupal.org Subject: [development] user deletion
Hi there!
There have been a lot of problems/discussions when it comes to Drupal's handling of deleted user accounts.
The problems did arise from the fact that we did leave user information in some places (notably node authorship, etc).
The discussions did arise from the fact whether we should keep the content or not.
I did propose to fix the problems (http://drupal.org/node/53348#comment-82298) and retain the content. it would be easy to do a contrib module which would delete the content instead (just make sure your user hook gets called befor the one in node.module). I think this approach is least destructive and leaves opportunities for other approaches.
Jose and Zen did provide a patch (http://drupal.org/files/issues/user_delete_3_0.patch) which I will be glad to commit if I get otld it works by an independend review.
If you disagree with this approach and thinks it does not allow you to do something you think that Drupal should allow you to do, please let me know too. But you better be quick about it. :p
Cheers, Gerhard
Walt Daniels wrote:
This seems to make everything deleted to belong to anonymous. At that point
Yes.
they are all indistinguishable, i.e. you can't tell which ones were spammers and really should disapear entirely. So a very aggressive delete spammers should be done first. Someone needs to write the delete spammer module as a prerequisite to applying this patch.
No, I won't wait for that. If you want to keep the content association, you can simple block a user. This way no data will be removed or changed (other than the user account status). Karoly also tells me that he can use forms API to completely remove the "delete user" option. Cheers, Gerhard
Gerhard Killesreiter wrote:
The discussions did arise from the fact whether we should keep the content or not.
I think it's absolutely obvious that the content must remain. However, if you're going to assign all deleted content to one account, can it please not be Anonymous User? I'd suggest 'deleted user' but actually just making the reassignment target user-selectable would be by far the most useful implementation. If I'm deleting someone, I could then a) Make an account called 'Deleted Troll Idiot' and move content to it, or b) In my intranet, delete a departing staff member and reassign all her material to her successor, or c) Fill in your own value for c) here. -- ------------------------------------------- John Handelaar E john@handelaar.org T +353 21 427 9033 M +353 85 748 3790 http://handelaar.org ------------------------------------------- Work in progress: http://dev.vocalvoter.com -------------------------------------------
On 3/27/06, John Handelaar <john@userfrenzy.com> wrote:
Gerhard Killesreiter wrote:
The discussions did arise from the fact whether we should keep the content or not.
I think it's absolutely obvious that the content must remain.
However, if you're going to assign all deleted content to one account, can it please not be Anonymous User?
I'd suggest 'deleted user' but actually just making the reassignment target user-selectable would be by far the most useful implementation.
If I'm deleting someone, I could then
a) Make an account called 'Deleted Troll Idiot' and move content to it, or
b) In my intranet, delete a departing staff member and reassign all her material to her successor, or
c) Fill in your own value for c) here.
-- ------------------------------------------- John Handelaar
E john@handelaar.org T +353 21 427 9033 M +353 85 748 3790 http://handelaar.org ------------------------------------------- Work in progress: http://dev.vocalvoter.com -------------------------------------------
I second b). That would be very useful indeed. Ultimately c) is the best option as it allows anything you would want to do. Adam
John Handelaar wrote:
Gerhard Killesreiter wrote:
The discussions did arise from the fact whether we should keep the content or not.
I think it's absolutely obvious that the content must remain.
This is how it is now.
However, if you're going to assign all deleted content to one account, can it please not be Anonymous User?
Too late.
I'd suggest 'deleted user' but actually just making the reassignment target user-selectable would be by far the most useful implementation.
If I'm deleting someone, I could then
a) Make an account called 'Deleted Troll Idiot' and move content to it, or
b) In my intranet, delete a departing staff member and reassign all her material to her successor, or
c) Fill in your own value for c) here.
I think you can do that through a contrib module, at least you can make sure that the content is assigned to another user but Anonymous, simply make sure you hook gets called first. Cheers, Gerhard
Gerhard Killesreiter wrote:
John Handelaar wrote:
However, if you're going to assign all deleted content to one account, can it please not be Anonymous User?
Too late.
So you committed it anyway, despite asking for objections? May I ask what the point was of your original message? The old user deletion may have been broken but it was far less destructive to data than this. jh
John Handelaar wrote:
Gerhard Killesreiter wrote:
John Handelaar wrote:
However, if you're going to assign all deleted content to one account, can it please not be Anonymous User?
Too late.
So you committed it anyway, despite asking for objections?
May I ask what the point was of your original message?
The old user deletion may have been broken but it was far less destructive to data than this.
I'm sure that killes saw your objection, but decided that the benefits of the patch outweigh the costs. You can disagree, but he also has the right to make this decision. His call for objections does not imply that he has to stop if any arise. This project is a never ending iteration. We'll get this right eventually. Most reasonable people will agree that assigning to the same uid as anonymous is not a perfect solution. Some rainy day, I'm sure a patch will arise which assigns all this content to uid=-1 or something like that and we'll begin the process again. -moshe
I like the idea of having a simple stub contrib module that does one version of this (e.g. assign content to anonymous). The module can be extended by those who need other ways of doing this (e.g. assign to another user, unpublish the content, ...etc.)
On 28-Mar-06, at 5:48 AM, Moshe Weitzman wrote:
John Handelaar wrote:
Gerhard Killesreiter wrote:
John Handelaar wrote:
However, if you're going to assign all deleted content to one account, can it please not be Anonymous User?
Too late. So you committed it anyway, despite asking for objections? May I ask what the point was of your original message? The old user deletion may have been broken but it was far less destructive to data than this.
I'm sure that killes saw your objection, but decided that the benefits of the patch outweigh the costs. You can disagree, but he also has the right to make this decision. His call for objections does not imply that he has to stop if any arise.
This project is a never ending iteration. We'll get this right eventually. Most reasonable people will agree that assigning to the same uid as anonymous is not a perfect solution. Some rainy day, I'm sure a patch will arise which assigns all this content to uid=-1 or something like that and we'll begin the process again.
Well..."some rainy day" -- anyone that wants the other functionality (which I'm definitely +1 for), please make a patch! I'm sure Gerhard will apply a nicely coded patch... -- Boris
Boris Mann wrote:
On 28-Mar-06, at 5:48 AM, Moshe Weitzman wrote:
John Handelaar wrote:
Gerhard Killesreiter wrote:
John Handelaar wrote:
However, if you're going to assign all deleted content
to one account, can it please not be Anonymous User?
Too late.
So you committed it anyway, despite asking for objections? May I ask what the point was of your original message? The old user deletion may have been broken but it was far less destructive to data than this.
I'm sure that killes saw your objection, but decided that the benefits of the patch outweigh the costs. You can disagree, but he also has the right to make this decision. His call for objections does not imply that he has to stop if any arise.
This project is a never ending iteration. We'll get this right eventually. Most reasonable people will agree that assigning to the same uid as anonymous is not a perfect solution. Some rainy day, I'm sure a patch will arise which assigns all this content to uid=-1 or something like that and we'll begin the process again.
Well..."some rainy day" -- anyone that wants the other functionality (which I'm definitely +1 for), please make a patch! I'm sure Gerhard will apply a nicely coded patch...
Not in this development cycle. As I explained it is easy enough to do what John wants using a rather small contrib module. Cheers, Gerhard
Gerhard Killesreiter wrote:
Not in this development cycle. As I explained it is easy enough to do what John wants using a rather small contrib module.
OK, I'm game. Someone got a pointer on how to override the user editing form's delete button? -- ------------------------------------------- John Handelaar E john@handelaar.org T +353 21 427 9033 M +353 85 748 3790 http://handelaar.org ------------------------------------------- Work in progress: http://dev.vocalvoter.com -------------------------------------------
John Handelaar wrote:
Gerhard Killesreiter wrote:
Not in this development cycle. As I explained it is easy enough to do what John wants using a rather small contrib module.
OK, I'm game.
Someone got a pointer on how to override the user editing form's delete button?
Anyone? There's something in Forms API for this but there are no docs for form_alter anywhere. -- ------------------------------------------- John Handelaar E john@handelaar.org T +353 21 427 9033 M +353 85 748 3790 http://handelaar.org ------------------------------------------- Work in progress: http://dev.vocalvoter.com -------------------------------------------
http://drupaldocs.org/api/head/function/hook_user Write your hook to reassign the comments when $op = 'delete' On 3/29/06, John Handelaar <john@userfrenzy.com> wrote:
John Handelaar wrote:
Gerhard Killesreiter wrote:
Not in this development cycle. As I explained it is easy enough to do what John wants using a rather small contrib module.
OK, I'm game.
Someone got a pointer on how to override the user editing form's delete button?
Anyone?
There's something in Forms API for this but there are no docs for form_alter anywhere.
-- ------------------------------------------- John Handelaar
E john@handelaar.org T +353 21 427 9033 M +353 85 748 3790 http://handelaar.org ------------------------------------------- Work in progress: http://dev.vocalvoter.com -------------------------------------------
John Handelaar wrote:
John Handelaar wrote:
Gerhard Killesreiter wrote:
Not in this development cycle. As I explained it is easy enough to do what John wants using a rather small contrib module.
OK, I'm game.
Someone got a pointer on how to override the user editing form's delete button?
Anyone?
There's something in Forms API for this but there are no docs for form_alter anywhere.
http://api.drupal.org/api/HEAD/function/hook_form_alter Basically you need to find the right form name (user_edit in this case) and unset or alter the right form element. Cheers, Gerhard
On 3/29/06, Moshe Weitzman <weitzman@tejasa.com> wrote:
Some rainy day, I'm sure a patch will arise which assigns all this content to uid=-1 or something like that and we'll begin the process again.
thanks for mentioning that uid = -1 thing, moshe... that kind of got me thinking, maybe we could implement a new system, where there are a whole bunch of 'system' users in Drupal (kind of like you have 'system' users in Unix, such as a 'web server user' and a 'firewall' user), all of which have negative uids. This would be consistent with the way we use negative IDs to specify dynamic menu items, and positive IDs to represent permanent ones. Some candidates for 'Drupal system users' that come to mind would be 'cron' and 'deleted'. Having now committed the crime of suggesting a new feature when I should be fixing 4.7 bugs, I will now face my punishment of death by firing squad... ;-) Jaza.
John Handelaar wrote:
Gerhard Killesreiter wrote:
John Handelaar wrote:
However, if you're going to assign all deleted content
to one account, can it please not be Anonymous User?
Too late.
So you committed it anyway, despite asking for objections?
May I ask what the point was of your original message?
I didn't commit it right away, but waited a few hours. In case you didn't notice: The development of Drupal has been sped up in order to get 4.7 out of the door. The patch did also exist for a few days before I committed it.
The old user deletion may have been broken but it was far less destructive to data than this.
Yes, it was broken. Now I consider it fixed. It removes all traces of the user from the system. That is what most people will consider to be the purpose of a delete function. If you don't want that to happen, don't delete users but block them. Cheers, Gerhard
participants (9)
-
Adam Cooper -
Boris Mann -
Earl Dunovant -
Gerhard Killesreiter -
Jeremy Epstein -
John Handelaar -
Khalid B -
Moshe Weitzman -
Walt Daniels