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

coretasks: fix malformed MODE command in startup() #1544

Merged
merged 1 commit into from
Apr 5, 2019

Conversation

dgw
Copy link
Member

@dgw dgw commented Apr 5, 2019

bot.write() joins the elements of a sequence type (tuple, here) with a space already, so including a space in 'MODE ' caused Sopel to send MODE  SopelsNick +modes. Technically, that's invalid.

Discovered while trying to test #1470 on a network with actual support for echo-message, when darwin.network disconnected the bot during registration with the message "ERROR :Received malformed line". Annoying because I was trying to test something else, but useful in the end.

bot.write() joins the elements of a sequence type (tuple, here) with a
space already, so including a space in `'MODE '` caused Sopel to send
`MODE  SopelsNick +modes`. Technically, that's invalid.

Discovered while trying to test #1470 on a network with actual support
for `echo-message`, when darwin.network disconnected the bot during
registration with the message "ERROR :Received malformed line". Annoying
because I was trying to test something else, but useful in the end.
@dgw dgw added the Bugfix Generally, PRs that reference (and fix) one or more issue(s) label Apr 5, 2019
@dgw dgw added this to the 6.6.6 milestone Apr 5, 2019
@dgw dgw requested review from Exirel and HumorBaby April 5, 2019 01:19
Copy link
Contributor

@HumorBaby HumorBaby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏👏👏

Copy link
Contributor

@Exirel Exirel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pretty straightforward fix.

@dgw dgw merged commit 20f2ca9 into 6.6.x Apr 5, 2019
@dgw dgw deleted the coretasks-malformed-mode branch April 5, 2019 16:03
dgw added a commit that referenced this pull request Apr 9, 2019
Just like #1544, but in the `admin.py` module instead of coretasks.

This was the only relevant occurrence I could find with a search for
strings with trailing spaces. Hopefully after this, we're golden.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bugfix Generally, PRs that reference (and fix) one or more issue(s)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants