interactions.py
interactions.py copied to clipboard
feat!: Implement ``AllowedMentions`` object
About
This pull request adds AllowedMentions and AllowedMentionTypes objects to work with allowed_mentions
Checklist
- [x] I've ran
pre-committo format and lint the change(s) made. - [x] I've checked to make sure the change(s) work on
3.8.6and higher. - [ ] This fixes/solves an Issue (If existent):.
- resolves #
- I've made this pull request for/as: (check all that apply)
- [x] Documentation
- [x] Breaking change
- [x] New feature/enhancement
- [ ] Bugfix
I don't want this to be breaking, so please add an
_._json if isinstance(_, Class) else _condition to where allowed mentions is used
Okay. Will do. What about typehinting?
- Keep current.
Optional[Union[AllowedMentions, Dict[str, list]]]Optional[Union[AllowedMentions, Dict[str, List[Union[str, int]]]]]Optional[Union[AllowedMentions, dict]]
I don't want this to be breaking, so please add an
_._json if isinstance(_, Class) else _condition to where allowed mentions is usedOkay. Will do. What about typehinting?
- Keep current.
Optional[Union[AllowedMentions, Dict[str, list]]]Optional[Union[AllowedMentions, Dict[str, List[Union[str, int]]]]]Optional[Union[AllowedMentions, dict]]
Late response, sorry, 4 is fine
Done