matrix-org / matrix-appservice-irc

Node.js IRC bridge for Matrix
Apache License 2.0
460 stars 149 forks source link

Re-invite idle kicked users to Matrix rooms #904

Open Half-Shot opened 4 years ago

Half-Shot commented 4 years ago

Several users are unhappy that they are kicked from a Matrix room because the IRC bridge has decided to quit them. This is annoying, but it should only happen to the small number of users not interacting with matrix for a long time. We cannot allow these users to stay in the rooms, but it would be possible to re-invite them to the rooms after kicking if they so wish.

This would need to be opt-in, otherwise we would end up murdering synapse with invites and would also invite a lot of people who will never return. However, I think this represents the fairest way to make both sides happy.

MakeItGreatAgain commented 4 years ago

Thanks for taking the proposal seriously - I'd also like to add that, combined with a Matrix room setting of "Allow all history since invite", users who are kicked from a Matrix room but then re-invited won't miss out on the backlog, which was our biggest concern.

We've mitigated it by making the room history fully public for several of our rooms, but that isn't always going to be an option for certain rooms or for other room admins.

Also, if it would be technically feasible (and politically possible), another great enhancement to the proposed re-invite system would be to allow the admins of the Matrix room to choose the re-invite setting by default for users in their room, so each new user wouldn't need to do it themselves. Many Matrix users in our rooms are only vaguely aware the room is even bridged.

We are bridged not just to freenode but to multiple other IRC networks with our own bridging (meshirc), and use power-level synchronization, so it's also the case that an idle IRC who might not even be aware of Matrix could have Matrix "puppet" could be kicked from IRC by appservice-irc just for being idle on IRC, and due to the PL synchronized they would be kicked from the IRC channel as well, which isn't intuitive.

I our case we would be able to work around this by making a special-case exemption to the PL synchronization, so the high-power-level appservice-irc user in the Matrix room is not an op on the meshirc side. In that case, rather than being kicked from both Matrix and meshirc (due to Matrix->freenode birding they aren't even aware of) their puppet would just be rejoined to the Matrix room automatically when speaking on IRC after their long idle period, and be blissfully unaware of things on the Matrix side.

The default would obviously be to require the user to opt-in to receive the invite if the Matrix room admins do not choose to enable it by default for their rooms users.

I know our particular setup is complex and atypical, so I appreciate the your willingness to work with us to find solutions for this issue.

piegamesde commented 2 years ago

As noted in https://github.com/matrix-org/matrix-appservice-irc/issues/1268#issuecomment-809386047, re-inviting users does not really work. Even if they get the notification, there is still some significant loss. An option to not kick users at all for being idle would be the preferred solution.