options: deprecate global plugin arguments#5140
Merged
gravyboat merged 1 commit intoFeb 3, 2023
Merged
Conversation
- Raise `StreamlinkDeprecationWarning` when `is_global=True` - Remove all global plugin arguments and replace them with simple option lookups on the Streamlink session instance - Remove global argument detection in custom Sphinx plugins extension - Remove supported plugins list from custom Sphinx argparse extension and remove respective setup from `setup_plugin_args` in the CLI module - Add deprecation note to the docs - Update tests - Check whether builtin plugins define global plugin arguments - Capture deprecation warnings
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
StreamlinkDeprecationWarningwhenis_global=Truesetup_plugin_argsin the CLI moduleThis is partly cherry-picked from the (current state of the) first commit of #5033 where global plugin arguments get removed, and it instead deprecates the usage of global plugin arguments and just removes them from Streamlink's builtin plugins and the docs.
Very likely unnecessary, because I don't think global plugin arguments are used by third party plugin implementations, but just in case, deprecating them prior to publishing a release with a breaking change is probably a better idea.
Note that this will remove the "supported plugins" list from the description of the
--mux-subtitlesCLI argument. In a future change, more metadata could be added to the plugin modules which chould then be shown in the docs and man page (via the custom argparse extension). The--helptext however won't be able to read plugin module metadata like this.