TCCPP / wheatley

Wheatley discord bot for the Together C & C++ discord server
Other
13 stars 20 forks source link

Wheatley wipes out 🔴 and other such reactions when someone loses their root role #68

Closed Eisenwave closed 6 months ago

Eisenwave commented 10 months ago

The current system would unintentionally erase all historical decisions that a staff member has made in the past on #server-suggestions

This is obviously a bug. Possible fixes:

jeremy-rifkin commented 10 months ago

Thanks for opening this issue. This isn't actually a bug, it's intended behavior for all non-roots to not have these reactions in server-suggestions. The solution is probably going to be to go through the action log and have wheatley re-apply any lost reactions and that way wheatley controls the reactions.

Eisenwave commented 10 months ago

Thanks for opening this issue. This isn't actually a bug, it's intended behavior for all non-roots to not have these reactions in server-suggestions. The solution is probably going to be to go through the action log and have wheatley re-apply any lost reactions and that way wheatley controls the reactions.

If something is missing from the action log (due to outages or general unreliability), I've also left some comments in the form of

🔴 reason

on a number of suggestions. Those could also be used to automatically restore the historical reactions.

Also, I've given it some more thought, and a time limit really wouldn't work since people can scroll up indefinitely into the past and leave reactions on old suggestions. I don't think it's intended behavior that Wheatley wipes out the historical reactions of former root users (even though it's intended that non-roots generally cannot leave reactions), so I still see it as a bug that it does that. It vandalizes server history and makes it unclear what decisions have been made historically by whom. After all, if you lost your root role, you wouldn't want Wheatley to just delete all the staff decisions you've ever made from the public record.

Since a time limit doesn't really solve the issue, it may be necessary to hard-code root users, or whitelist users who have had the root role at any point (as determined via the database).

jeremy-rifkin commented 10 months ago

If something is missing from the action log (due to outages or general unreliability)

There shouldn't be anything missing in the action log, quite a lot of work was put into state recovery for server suggestion tracking. Most of the complexity in that module comes from state recovery actually.