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

fix(ext.bridge): Bridge options & bool converter breaking sometimes #1999

Merged

Conversation

Middledot
Copy link
Member

Summary

1999!!!!!!

Fix #1988
Fix #1972

  1. When the user uses discord.Option, the BridgeOption class will not be used because of the import order.
  2. CONVENIENTLY, the only non-class converter in the converter mapping (in ext.bridge) is the one for booleans, which is why issubclass throws everywhere. There are no errors when a direct typehint is used for the option (e.g. opt1: bool), but all the other ones still do.

Information

  • This PR fixes an issue.
  • 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, typehinting,
    examples, ...).

Checklist

  • I have searched the open pull requests for duplicates.
  • If code changes were made then they have been tested.
    • I have updated the documentation to reflect the changes.
  • If type: ignore comments were used, a comment is also left explaining why.
  • I have updated the changelog to include these changes.

@Middledot Middledot added the ext.bridge Relating to ext.bridge label Apr 3, 2023
@Middledot Middledot requested review from a team as code owners April 3, 2023 03:04
@plun1331 plun1331 added bug Something isn't working status: awaiting review Awaiting review from a maintainer labels Apr 3, 2023
@Lulalaby
Copy link
Member

Lulalaby commented Apr 3, 2023

@Middledot conflicts

Signed-off-by: Middledot <78228142+Middledot@users.noreply.github.com>
@Middledot
Copy link
Member Author

Resolved

@Lulalaby Lulalaby enabled auto-merge (squash) April 3, 2023 23:51
@Lulalaby Lulalaby requested a review from BobDotCom April 3, 2023 23:51
@BobDotCom BobDotCom disabled auto-merge April 17, 2023 16:06
@BobDotCom BobDotCom merged commit 4584bec into Pycord-Development:master Apr 17, 2023
28 checks passed
@Middledot Middledot deleted the fix-1972-bool-opt-broke branch April 17, 2023 17:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working ext.bridge Relating to ext.bridge status: awaiting review Awaiting review from a maintainer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

discord.Option doesn't work with bridge commands Issubclass Error with BridgeCommands.
4 participants