forum

Receiving /np with IRC & python

posted
Total Posts
2
Topic Starter
c1aymore
Hello!
I'm developing an IRC bot, and I'm having trouble handling the /np (now playing) command. I need help understanding the exact format of the message that is generated when this command is used.

Thanks in advance!
ekgame
Here's the regex Tillerino uses: https://github.com/Tillerino/Tillerinobot/blob/master/tillerinobot/src/main/java/tillerino/tillerinobot/handlers/NPHandler.java#L34-L45

As I understand it, Python does not support named groups, so I adapted the regex for it: https://regex101.com/r/ocIU58/1

I wrote some example code for how to use it in Python: https://www.online-python.com/REuiIKkr3a
Please sign in to reply.

New reply