Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

💡 Detect thread owners even if start message is deleted #49

Closed
MarcusOtter opened this issue Feb 1, 2022 · 1 comment · Fixed by #34
Closed

💡 Detect thread owners even if start message is deleted #49

MarcusOtter opened this issue Feb 1, 2022 · 1 comment · Fixed by #34
Labels
improvement 💡 Improvement suggestion

Comments

@MarcusOtter
Copy link
Owner

MarcusOtter commented Feb 1, 2022

Is your request for improvement related to a problem? Please describe.
To determine the original authors of auto-threads, we look at the message it was created by in the parent channel. However, if a user deletes this message and then tries to archive the thread, they will get an error message saying that the thread owner could not be determined. This happens at least 10+ times every day and I imagine it's frustrating for users as they can no longer do anything with the thread.

This is because our author identification relies on that first message.

Example:

  • User A doesn't know that a #help channel is auto-threaded and replies to 3 users in the channel as they would normally.
  • User A realizes their mistake as they see the threads on their replies
  • User A quickly removes the messages in the #help channel, praying that nobody sees it 🙏
  • User A then goes to the threads and click the archive button. Unfortunately, we cannot verify that they are the owners anymore, and the threads are stuck there until they are auto-archived.
  • User A is disappointed with the bot, and mods have manual work to clean up the threads.

Describe the solution you'd like
In the case where we cannot determine the author from the message, we should determine thread ownership by just mentioning the user that created the thread in the first auto-thread message, and then reading the first mention of the auto-thread message.

image

Downsides/quirks:

  • If people remove the ping in the auto-thread message, we don't have that "safety net". Not a big deal.
  • If people decide to ping some OTHER user first in the auto-thread message, the bot considers someone else to be the owner in the case where the start message has been deleted. This is suboptimal, but it's also not exactly worse than what we have now (at least we have one more person that can close the thread 😄)
  • We will ping users twice (💡 Don't ping users twice  #26)

Describe alternatives you've considered

  • Leave it like it is today, not great.
  • Storing information about every thread created and their owner on disk, not great.

Additional context
We use a mention instead of the tag (user#1234) because user names can change. We also don't want to send the userID in the thread message, that gets very cluttery.

@MarcusOtter MarcusOtter added the improvement 💡 Improvement suggestion label Feb 1, 2022
This was referenced Feb 1, 2022
Merged
@MarcusOtter MarcusOtter changed the title 💡 Improvement: Detect thread owners even if start message is deleted 💡 Detect thread owners even if start message is deleted May 26, 2022
@MarcusOtter
Copy link
Owner Author

This issue was undone with #68 and is no longer implemented. If a thread starting message is deleted (but the thread persists), the thread author will no longer be able to archive/change title.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement 💡 Improvement suggestion
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant