disnake
disnake copied to clipboard
refactor(appinfo)!: improve application models
Summary
Refactors application models, deduplicating and generally merging related code.
The diff is fairly unreadable as-is, skipping the first commit (that just moves PartialAppInfo above AppInfo) improves readability quite a bit.
tl;dr on the important changes, see changelog for everything:
- new hierarchy:
PartialAppInfo < AppInfo < BotAppInfo(whereBotAppInfois equivalent to the oldAppInfo)- note: this shouldn't have any practical effect on user code unless these types are created there
-
AppInfo.summaryis no more (deprecated in previous version) -
Invite.target_application(which is nowAppInfo) contains more fields - now using the correct
cover_imageurl format
Checklist
- [x] If code changes were made, then they have been tested
- [x] I have updated the documentation to reflect the changes
- [x] I have formatted the code properly by running
task lint - [x] I have type-checked the code by running
task pyright
- [x] This PR fixes an issue
- [x] This PR adds something new (e.g. new method or parameters)
- [x] This PR is a breaking change (e.g. methods or parameters removed/renamed)
- [ ] This PR is not a code change (e.g. documentation, README, ...)
@shiftinv would you please resolve conflicts?
would you please resolve conflicts?
@onerandomusername done.
@shiftinv would you please resolve conflicts again?