Skip to content

Message intents are dead

Open
Open

Description

Task summary

Original issue description follows.


The intents feature is long dead, having been pulled from IRCv3 almost three years ago (ircv3/ircv3-specifications#271). This affects Sopel in a few ways.

First, we have a @module.intent decorator that is now obsolete, named for a dead specification that nobody is going to implement.

Second, Sopel internally handles CTCP ACTIONs (the only use case I was ever aware of for intents) by stripping the CTCP bytes and adding the "ACTION" intent to the trigger instead. That's why plugin functions wanting to act only upon ACTION messages must use @module.intent('ACTION').

Third, obviously the intents attribute added to Sopel callables with intent filters is also obsolete.

In short, there's a fair bit of restructuring to do here. A quick chat with the IRCv3 folks on freenode tells me that CTCP ACTIONs themselves aren't going anywhere, so we should be fine designing an API around those as they currently exist. Maybe we add @module.action, like @module.echo, and kill off regular @module.commands-decorated callables receiving ACTION messages at all. (That would take care of an oddity that exists in current Sopel 6.x, wherein one can do /me .command and Sopel will act on it just like a regular message, which can be unexpected.)

That same chat on IRC also told me that the direct replacement for intents is message-tags. We don't support those at all, at least not in a way that plugins can use.

I'd like to get this done for Sopel 7.0, but only deprecating @module.intent and replacing it with something else is truly important. Opening message-tags up in the plugin API can wait until 7.1+.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions