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

Use get_bot_mapping to generate bot help (Resolves issue #9329) #9330

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

DanielBaulig
Copy link

@DanielBaulig DanielBaulig commented Apr 3, 2023

Summary

Resolves issue: #9329

This change makes it so that DefaultHelpCommand uses it's mapping argument (generated by get_bot_mapping()), to generate it's help output. This change does not directly change DefaultHelpCommand behavior and will continue to generate the same output, but allows subclasses to override get_bot_mapping to make alterations to the return value of get_bot_mapping to, for example, add or remove elements.

Checklist

  • If code changes were made then they have been tested.
    • I have updated the documentation to reflect the changes. (Not applicable, actually behavior now matches documentation)
  • This PR fixes an issue (Have DefaultHelpCommand use get_bot_mapping #9329)
  • This PR adds something new (e.g. new method or parameters).
  • This PR is a breaking change (e.g. methods or parameters removed/renamed)
  • This PR is not a code change (e.g. documentation, README, ...)

This change makes it so that `DefaultHelpCommand` uses it's `mapping` argument (generated by `get_bot_mapping()`), to generate it's help output. This change does not directly change DefaultHelpCommand behavior and will continue to generate the same output, but allows subclasses to override get_bot_mapping to make alterations to the return value of get_bot_mapping to, for example, add or remove elements.
Copy link
Owner

@Rapptz Rapptz left a comment

Choose a reason for hiding this comment

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

This PR seems to change a lot of the code for what, at a glance, would appear to be a minimal change. Likewise, there are trailing spaces which would fail CI. I recommend running black on the files.

For example, this PR seems to change the grouping logic that was set, and seems to remove comments and change function names which doesn't seem to be in the spirit of the change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants