sir-lancebot icon indicating copy to clipboard operation
sir-lancebot copied to clipboard

`.extension list` incorrectly feed lines to the paginator

Open Akarys42 opened this issue 4 years ago • 1 comments

Description

Instead of putting each line as a separate entry in the lines parameter, .extension list will create a line with newline characters in it, like so

https://github.com/python-discord/sir-lancebot/blob/b0bddb905b8b7e311aad103570c8245f7c0a0683/bot/exts/utils/extensions.py#L164-L168 While this can seem harmless, this will cause the line length check to fail, and raise a RuntimeError

https://github.com/python-discord/sir-lancebot/blob/b0bddb905b8b7e311aad103570c8245f7c0a0683/bot/utils/pagination.py#L58-L59

Steps to Reproduce

It seems like that with the current cogs we have, running .extension list will unconditionally raise an exception

Solution

The paginator of the Python bot should be ported over to this bot.

Would you like to implement a fix?

  • [ ] I'd like to implement the bug fix
  • [x] Anyone can implement the bug fix

Akarys42 avatar Nov 30 '20 08:11 Akarys42

Sentry issue: SIR-LANCEBOT-25

sentry-io[bot] avatar Nov 30 '20 08:11 sentry-io[bot]

Closing this since :

  • the bot paginator has been ported to botcore and used here
  • running the command doesn't raise any exceptions.

shtlrs avatar Mar 22 '24 14:03 shtlrs