Skip to content
This repository has been archived by the owner on May 14, 2023. It is now read-only.

Room purge bot #82

Open
turt2live opened this issue Sep 19, 2017 · 8 comments
Open

Room purge bot #82

turt2live opened this issue Sep 19, 2017 · 8 comments

Comments

@turt2live
Copy link
Owner

turt2live commented Sep 19, 2017

Kick inactive/idle users.

Does not apply for redacting messages. That is #81

@turt2live
Copy link
Owner Author

This needs some thought:

  • What is needed to mark a user as inactive?
    • Presence data is unreliable
    • Solely basing the metric off of "last message" could be a problem due to federation
    • Read receipts could be argued to be markers of activity
    • State issues and other federation instabilities may cause false positives

@MurzNN
Copy link

MurzNN commented Sep 21, 2017

I think that the main metric must be that user is offline more than XX days. But this can give problems with homeservers that disable presence status, like Matrix.org now.

About federation instabilities - the normal Matrix homeservers must not have long offline or breaked federation status (more than week), only short downtimes for maintenance less than 1-3 days. So I think we can ignore issues with that problematic servers. And we do not global rule on server side, but only per-room bot that can be customized by user, so let's forget about potential federation problems here.

For large rooms like Matrix HQ the main task is kick old users from dead homeservers, but, as I understand, bot can't lookup user homeserver status, only user presence.

Best way will be do optional per-room configuration for bot - which metric to use for kick users. So for some rooms good way is look at read receipts (if user disable read receipts manually - this will be the user problem), for other - last user message (if user don't write anything more than 3 month - let's kick it), for third - kick all users that offline more than 1 month, etc.

So will be good to see per-room configurable rules in bot for kicking, like this:

User kick rules:

  • Missing read receipts more than [ ] days (if user disable read reciepts - it will be the user problem)
  • Don't send events more than [ ] days (send message, change name, avatar, reactions in future, etc)
  • Don't post message more than [ ] days (some rooms not want to have users that not posting long time)
  • Inactive more than [ ] days (if user don't do full logout on mobile client - it will stay always in inactive state, not offline)
  • Offline more than [ ] days

@MurzNN
Copy link

MurzNN commented Sep 21, 2017

Also will be good to see whitelist rules for ignore specific users from kicking - by user power level in room (don't kick moderators), by homeserver, login, name, or full Matrix id mask like @*:myhomeserver.org, @*_bot:*.

@MurzNN
Copy link

MurzNN commented Sep 21, 2017

Will be also good to integrate purge old room messages feature to this bot, for solve issues like
https://github.com/vector-im/riot-web/issues/2497
matrix-org/synapse#2315
matrix-org/synapse#1480
matrix-org/synapse#1730

@turt2live
Copy link
Owner Author

Thank you for the input. It should help someone who is looking at potentially implementing this bot. The scope of the bot should be limited to just people though, messages are a different concern.

@MurzNN
Copy link

MurzNN commented Sep 21, 2017

Ok, I create separate issue about room message purge: #85

@non-Jedi
Copy link

dup of #9

@ordinarygulp
Copy link

Would like to see this, for future inactive users

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants