PyThOn, you may consider doing this two ways to avoid an error:> on :text:!join:#: .join #$$2Or leave a space between the cmd and the asterisk:
on *:text:!join *:#: .join #$2
this way the $2 has to be filled with a value before the code can be executed. The dash after $2 is not necessary, 'cause a channel name can never consist in a space to be two tokens or more -- not that I have seen thus far.