-
Notifications
You must be signed in to change notification settings - Fork 200
Refactor and consolidate mixins #1564
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
base: master
Are you sure you want to change the base?
Refactor and consolidate mixins #1564
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR refactors the mixin architecture by introducing consolidated mixin classes for each media type (MovieMixins, ShowMixins, etc.), significantly reducing import complexity across the codebase while maintaining identical functionality.
Key changes:
- Created 12 new consolidated mixin classes in
plexapi/mixins.py(MovieMixins, ShowMixins, SeasonMixins, EpisodeMixins, ClipMixins, ArtistMixins, AlbumMixins, TrackMixins, PhotoalbumMixins, PhotoMixins, CollectionMixins, PlaylistMixins) - Updated all media type class definitions to use consolidated mixins instead of listing individual mixins
- Enhanced type annotation in
_parseQueryFeedmethod
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| plexapi/mixins.py | Adds 12 new consolidated mixin classes and improves type annotation for filtersDict |
| plexapi/video.py | Updates Movie, Show, Season, Episode, and Clip classes to use consolidated mixins |
| plexapi/audio.py | Updates Artist, Album, and Track classes to use consolidated mixins |
| plexapi/photo.py | Updates Photoalbum and Photo classes to use consolidated mixins |
| plexapi/collection.py | Updates Collection class to use consolidated mixins |
| plexapi/playlist.py | Updates Playlist class to use consolidated mixins |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 17 out of 17 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Description
Refactor mixins for each media type to reduce number of imports.
Checklist: