Commit Graph

4530 Commits

Author SHA1 Message Date
bastimeyer 9a0c64a78a chore: update Gitter link in issue template config 2023-02-14 12:31:58 +01:00
bastimeyer 948160087e docs: rewrite, fix and improve CLI tutorial 2023-02-12 12:15:02 -08:00
bastimeyer a0a5af60b0 docs: remove Open Collective
- Rewrite the documentation's donate page
  - Remove donation infos from individual team members
  - Add all team members
  - Fix GitHub username regex in Sphinx extension
- Rewrite the project README
  - Use HTML for centered text, add logo, update badges
  - Rephrase text sections
  - Remove Open Collective and update support section
- Replace all links to Open Collective with a link to the latest docs
2023-02-11 12:10:36 -08:00
bastimeyer d91d2a8ee5 tools: remove export-subst from .gitattributes
Added by 416c834 and made obsolete by 9b0815d
2023-02-11 12:50:48 +01:00
bastimeyer 13915cf86d chore: fix issues introduced by ruff 0.0.245 2023-02-11 12:45:05 +01:00
bastimeyer ffca7bdbd8 tools: add .git-blame-ignore-revs
See `man git-blame`, `git blame --ignore-revs-file <file>`
and the `blame.ignoreRevsFile` git config option.
2023-02-10 12:30:31 -08:00
bastimeyer 4622c9728e chore: add "ISC" rules to ruff config 2023-02-09 11:48:40 -08:00
bastimeyer 17daf563a3 chore: add "C4" rules to ruff config 2023-02-09 11:48:40 -08:00
bastimeyer 57fa6f80e8 chore: add "COM" rules to ruff config 2023-02-09 10:26:50 -08:00
bastimeyer 9fd14e3f9d chore: add "Q" rules to ruff config 2023-02-09 10:26:50 -08:00
bastimeyer faab9200c7 chore: add "I" and "TID" rules to ruff config 2023-02-09 10:26:50 -08:00
bastimeyer 98596e9331 tools: replace flake8 with ruff 2023-02-09 09:54:14 -08:00
TaoziDB ce2c5e11db
plugins.nimotv: fix livestream stopping after couple of seconds (#5147) 2023-02-08 16:12:13 +01:00
bastimeyer 3094941958 plugins.youtube: restore /user/... URLs 2023-02-08 14:59:26 +00:00
bastimeyer 04da9f5cdc stream.hls: refactor various attribute parsers
- Turn methods into classmethods
- Emit warning messages on parsing failure
- Add unit tests
2023-02-07 09:58:03 +01:00
bastimeyer 3e83393811 stream.hls: refactor and fix attribute list parser
- Rewrite and fix attribute list regex
- Be more strict when parsing multiple attributes and expect the
  mandatory comma separator, but be lenient about spaces surrounding
  attributes (off-spec), similar to the old implementation
- Add missing support for signed decimal floating point numbers
- Fix invalid range of hexadecimal sequences and allow uppercase prefix
- Fix character range of enumerated strings being too narrow
- Fix character range of quoted strings
- Discard entire attribute list on parsing failure and emit warning
- Add unit tests
2023-02-07 09:58:03 +01:00
bastimeyer 9fa2d820a5 plugins.youtube: rewrite and fix matchers 2023-02-06 22:41:17 +01:00
bastimeyer 96627e7a0d build: include py.typed in package_data 2023-02-04 13:37:44 -08:00
bastimeyer 319a60f54f plugins.youtube: fix adaptive streams KeyError 2023-02-03 10:23:14 -08:00
bastimeyer 0589750c8f options: deprecate global plugin arguments
- 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
2023-02-03 10:21:31 -08:00
streamlinkbot fbb9ed6497 plugin.api: update useragents 2023-02-01 00:22:42 +00:00
bastimeyer 4b82f1f595 docs: improve loglevel help text 2023-01-30 16:17:49 +00:00
back-to 39dd8f898e plugins.funimationnow: deleted 2023-01-29 11:31:36 +01:00
back-to 25c04a6b26 plugins.schoolism: deleted 2023-01-29 11:26:42 +01:00
bastimeyer b135552df6 chore: add templates for GitHub discussions 2023-01-27 09:45:24 -08:00
bastimeyer 2f7396ba24 tools: check typing in docs dir separately 2023-01-26 09:42:34 -08:00
bastimeyer 317dc8efdc build: include icon.svg in sdist 2023-01-25 14:39:34 -08:00
bastimeyer ab0f4d88c2 release: 5.2.1 2023-01-23 23:37:32 +01:00
bastimeyer faece22c35 ci: revert deploy-pypi changes
Partially reverts de5bda806d
2023-01-23 23:27:39 +01:00
bastimeyer 932075c852 release: 5.2.0 2023-01-23 22:53:40 +01:00
bastimeyer 5340477207 stream.hls: warn when writing after discontinuity 2023-01-23 04:42:08 +01:00
bastimeyer 66244e32d7 tests.plugins: rewrite PluginCanHandleUrl tests
- Rewrite dynamic test parametrization
- Test named plugin matchers
- Update tests with named matchers accordingly
- Fix incorrect test class names
2023-01-22 13:56:49 +01:00
Ian Cameron e629975e71
plugins.earthcam: fix cam_name (#5110)
Co-authored-by: HappyPlotter <111639418+happyplotter@users.noreply.github.com>
2023-01-22 11:12:59 +01:00
Ian Cameron 90c1860580 plugins.tvp: add tvp.info 2023-01-20 21:55:53 +01:00
bastimeyer 91bf178e38 plugins.orf_tvthek: remove
Both HLS and DASH live streams are protected by DRM, which makes
a plugin rewrite and cleanup impossible.
2023-01-20 13:14:57 +00:00
bastimeyer 0c8375beb4 plugin: add support for named plugin matchers 2023-01-19 18:41:38 -08:00
Ian Cameron fe6f51aa75 plugins.ceskatelevize: update for ct24, sport and sportplus; add decko 2023-01-19 20:03:06 +01:00
bastimeyer c3f942beff chore: remove unneeded noinspection directives 2023-01-18 08:01:52 +01:00
Ian Cameron 7484f76a97 plugins.mixcloud: new plugin 2023-01-18 07:29:53 +01:00
bastimeyer 871f7f7b3a tests: fix warnings in CLI main tests
Prevent HTTP server from accidentally being launched and not closed
2023-01-14 20:14:33 -08:00
bastimeyer bce2ee43f3 tests: fix warnings in playeroutput tests
- close open file handles
- parametrize
2023-01-14 20:14:33 -08:00
bastimeyer 2d74c69882 tests: set filterwarnings=always via pytest config
- Add pytest config to pyproject.toml
- Set pytest 6.0.0 as minimum version via dev-requirements.txt
- Remove unneeded filterwarnings("always") calls from tests
2023-01-14 20:14:33 -08:00
bastimeyer fe9be00832 chore: ignore coverage in TYPE_CHECKING blocks 2023-01-14 07:47:08 +01:00
bastimeyer c211e5866e plugin.api.validate: deprecate text alias
- Deprecate text alias and raise StreamlinkDeprecationWarning on access
- Add deprecation to docs
- Replace validate.text with str in remaining plugins
- Update test
2023-01-13 11:27:11 -08:00
bastimeyer 6b415bbee6 tests: fix cmdline tests
Fix not being able to run `cli/test_cmdline*.py` tests independently.

`subprocess.Popen` can't be mocked as a whole until all plugins get
loaded first, otherwise this causes an issue with loading the Crypto
module in one of the plugins loaded by the Streamlink session.
2023-01-13 11:26:13 -08:00
bastimeyer 777d1be3de logger: add StreamlinkWarning
- Add `StreamlinkWarning` and `StreamlinkDeprecationWarning`
  and replace `FutureWarning`s
- Don't include the warning's origin in the warning logger if it's a
  subclass of `StreamlinkWarning`
- Update tests
2023-01-12 15:54:18 -08:00
bastimeyer d5b2981fbe logger: turn deprecation log msgs into warnings
- Replace all deprecation warning log messages with `FutureWarning`s
- Fix deprecated session options in tests
- Update and fix tests
2023-01-12 15:54:18 -08:00
bastimeyer a76cefe7ca logger: capture warnings
Add support for capturing warnings and logging them via Streamlink's
root logger on the warning log level. Use custom `WarningLogRecord`s
with a custom warning message format, and replace the record's
logger name with "warnings" and use the name of the warning type
as log level name when showing warnings.

This enables having proper `DeprecationWarning`s and `FutureWarning`s
in the code instead of just using the logger and its warning log level,
and those warnings can be filtered via the regular filtering mechanisms.

For example:
```
[warnings][deprecationwarning] Calling this method is deprecated
[warnings][futurewarning] Using this config file path is deprecated
```
2023-01-12 15:54:18 -08:00
bastimeyer 6556276940 exceptions: remove `url` arg from NoStreamsError 2023-01-12 09:49:02 -08:00
bastimeyer 109263b186 exceptions: update docs and fix NoPluginError
- Make `NoPluginError` inherit from `StreamlinkError`
  instead of `PluginError`
- Update and fix docstrings of all Streamlink exception classes
- Update list of exceptions in API docs
- Fix exports
2023-01-12 09:49:02 -08:00