Closed t33chong closed 6 years ago
I love the examples. :D Generally this seems good, but could you say a bit more about the use case that prompted it? I'm guessing there was some integration in Slack that triggered a Lita handler and you want to prevent that. Since Slack has the concept of "bot" users that is exposed through the API, I wonder if there is a way Lita (or maybe just lita-slack) can have a generic "ignore bots" mechanism that doesn't force the user to do a bunch of tedious configuration of ignore lists.
@jimmycuadra Thanks! Yeah, we have a Slack integration that tells us things like "Lita production deploy started" and it triggers our custom invalid command response because it starts with the name of the bot. I can certainly look into solving this within the lita-slack adapter, but an ignore feature could be useful for other purposes as well, like a user who is purposely spamming a channel by sending commands that trigger long responses from the bot.
like a user who is purposely spamming a channel by sending commands that trigger long responses from the bot
I see what you did there. XD
Closing cause I think https://github.com/litaio/lita-slack/issues/94 addressed the particular issue that prompted this.
Slack integration that tells us things like "Lita production deploy started" and it triggers our custom invalid command response because it starts with the name of the bot
This could be prevented by changing config.robot.name
to something more unique, no?
This adds a configuration option in which users to be ignored by the bot may be specified by ID, name, or mention name, preventing the possibility of an infinite loop in a chat channel where multiple bot users are present.