Change missing plugin to allow for filtering albums by release type #5587
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Addresses #2661.
Currently, the missing plugin when ran in album mode only allows for getting all release groups attached to a single artist. Users may want to restrict this search to only show releases of a specific type (such as albums or compilations). This CR adds a new
--release-type
flag to the missing plugin. If users want to filter to a specific type (or set of types), they simply need to provide this flag for every release type that they want included.As part of this change, the default behavior has been shifted to only select
album
type releases as is suggested in the issue- to avoid breaking default behavior I could easily switch this back. I am also wondering if it might make sense to address the following idea (#5101) in a follow-up.The tests I wrote are written using
pytest
, as it is suggested in the documentation to stay away fromunittest
. As a result, I required a slightly different mixin inheritance schema than is usually seen. If there are any other recommended ways to accomplish this I'd be happy to switch!To Do
docs/
to describe it.)docs/changelog.rst
to the bottom of one of the lists near the top of the document.)