Commit Graph

122 Commits

Author SHA1 Message Date
bastimeyer 115c2ed486 build: build and include plugins JSON in wheels 2024-02-14 13:26:18 +01:00
bastimeyer 13762836c2 build: remove versioningit build-req from sdist
- Replace `tool.versioningit.onbuild` hook with a custom implementation
  which replaces the entire `streamlink._version` module (similar to
  before) and which additionally removes `versioningit` from the
  `build-system.requires` field in `pyproject.toml` and which sets
  a static version string in `setup.py`
- Rewrite `streamlink._version` module
- Add and update comments
- Update docs
- Add tests
2023-10-22 19:45:31 +02:00
bastimeyer 50148a6f4e chore: drop support for Python 3.7 2023-07-02 21:04:09 +02:00
bastimeyer 57fa6f80e8 chore: add "COM" rules to ruff config 2023-02-09 10:26:50 -08:00
bastimeyer cc455586c5 ci: lint sphinx extensions and setup.py 2022-06-23 09:35:00 -07:00
bastimeyer d87b7dc9dd build: move imports in setup.py
Ensure that the error message can be shown on unsupported Python
versions trying to execute setup.py
2022-04-10 17:16:27 -07:00
bastimeyer 9b0815dbee build: add pyproject.toml, switch to versioningit
- Add basic pyproject.toml with build-system information
- Drop versioneer in favor of versioningit
- Delete versioneer install module and remove its setup.cfg config
- Replace `src/streamlink/_version.py` and load streamlink's version
  string via versioningit. The module's `__version__` export will get
  replaced by a static string on build-time when creating sdists/wheels,
  which results in the old versioneer behavior with support for
  editable installs.
- Make versioningit use the same version format as versioneer
- Update MANIFEST.in and .coveragerc
2022-04-10 07:55:31 +02:00
bastimeyer 89ab021c07 chore: drop support for Python 3.6 2022-04-10 07:35:19 +02:00
bastimeyer 2eb9689fac setup: include shell completions in sdist
- move build directory of the shell completions from /build/shtab to
  /completions due to an sdist restriction of setuptools and MANIFEST.in
- recursively include the /completions directory in MANIFEST.in
- update data_files path in setup.py (for inclusion in wheels)
- update .gitignore
2021-11-15 18:53:58 +01:00
bastimeyer aabd6af718 setup: drop iso-639/iso3166, default to pycountry
- drop iso-639 and iso3166 dependencies in favor of pycountry
- remove the `STREAMLINK_USE_PYCOUNTRY` env var switch from setup.py
- move dependencies list from setup.py to setup.cfg
- update utils.l10n and its tests
- update Windows installer config
- update docs
2021-11-14 11:42:36 -08:00
bastimeyer 9d371d9f3d setup: drop pycrypto support
- remove the `STREAMLINK_USE_PYCRYPTO` env var switch from setup.py
- sort dependencies list
- update dependencies section in install docs
  - sort dependencies table
  - rephrase notes column
2021-11-14 13:09:58 +01:00
bastimeyer aa7cf1453c plugin.api: implement WebsocketClient
- bump websocket-client requirement to >=1.2.1,<2.0
- avoid circular import by importing HTTPSession in session directly
- implement a common WebsocketClient based on the WebSocketApp API of
  websocket-client, so that plugins don't have to re-implement basic
  boilerplate code
- automatically apply User-Agent header
- automatically apply proxy settings
- set websocket log level (globally)
- add tests
2021-11-06 15:07:55 +01:00
bastimeyer 6cad2faf1f vendor: bump lxml to >4.6.4,<5.0
And remove the compat wheel installs on Windows for the CI runners, as
lxml 4.6.4 has fixed the missing python 3.10 wheels
https://pypi.org/project/lxml/4.6.4/#files
2021-11-02 20:28:45 -07:00
bastimeyer 7da6e676cc setup: remove NO_DEPS env var 2021-10-23 11:32:18 -07:00
bastimeyer 42ca168b27 setup: switch to declarative package metadata
- move static package metadata to setup.cfg
- rename deprecated license_file field to license_files

Remove setuptools arguments:
- test_suite:
  Unneeded, as we disable the deprecated setuptools test command

Keep dynamic setuptools arguments:
- version/cmdclass:
  For writing static version info via versioneer
- install_requires:
  Some dependencies still depend on special environment variables
  instead of package "extra" dependency fields
- entry_points:
  The `gui_scripts` entry point should only be set when building wheels
  for Windows via `--plat-name={win32,win-amd64,cygwin}`
- data_files:
  All data files are optional and should not cause the build to fail if
  they are missing, eg. when building from sdist
2021-10-23 10:43:37 -07:00
bastimeyer 06eba3bdbf setup: disable test command 2021-10-19 20:16:13 -07:00
bastimeyer 5b01621fd1 setup: show error on older python versions
Show an error message when the python_requires classifier of the
package gets ignored, so that users can't accidentally install
an incompatible version of Streamlink with their unsupported
Python version / environment.

Also bump the required version of pip to >=9 in dev-requirements.
2021-10-09 11:23:50 -07:00
bastimeyer 1549c41752 build: include bash and zsh completions in wheels 2021-09-26 10:22:40 +02:00
bastimeyer 300a67e495 vendor: add lxml dependency 2021-08-28 12:08:13 -07:00
back-to ac47d04e7c setup: update requests version >=2.26.0 and makeinstaller.sh
revert https://github.com/streamlink/streamlink/pull/3880
2021-08-22 12:31:59 +02:00
bastimeyer a1fd4edee6 vendor: downgrade requests to 2.25.1 on Windows
This temporarily fixes the issue of randomly failing tests on
Windows which seems to be related to the latest requests version
2.26 and requests-mock, where mocked request responses take an
random/arbitrary time to return data, which makes the
EventedHLSStreamWriter tests miss their time frames when writing
HLS segment data to the output buffer.

Since Windows builds of Streamlink don't rely on system python
packages like on most Linux distros for example, downgrading and
forcing an older version of requests on Windows should be fine.

This commit thus partly reverts 35cb8d9f and 29a25fc7 which fixed
the broken dependencies of the Windows installer and skipped the
randomly failing tests on Windows.
2021-07-23 20:25:03 -07:00
bastimeyer 35cb8d9f9a vendor: set requests to >=2.26.0,<3
- Bump requests to latest version:
  This replaces transitive dependency chardet with charset-normalizer
- Fix Windows installer dependencies:
  Upgrade dependencies and list them as wheels with strict versions,
  where possible.
  pynsist unfortunately doesn't support additional wheel checksums.
2021-07-15 15:27:27 -07:00
Alexis Murzeau c7bd7ec609 build: include .removed file in build
This file is required by tests when executing them with the build dir.
2021-04-01 06:12:39 +02:00
back-to 0f7ef003ea setup.py: require websocket-client>=0.58.0
Make sure all User use the same version where `callback(self, *args)` was changed.

Ref https://github.com/websocket-client/websocket-client/issues/669
2021-03-20 22:45:48 +01:00
bastimeyer 97205d2fa2 build: include man page in wheels 2020-12-30 11:40:48 +01:00
Forrest Alvarez ffac89315b Update author email to shared email 2020-12-07 03:56:21 +01:00
beardypig a585e88297 chore: sort imports, fix a dependency cycle and use absolute imports
Co-authored-by: bastimeyer <mail@bastimeyer.de>
2020-10-27 17:17:49 +01:00
Sebastian Meyer df6ab1249b
chore: drop support for Python 3.5 (#3269)
- Bump Python version requirement to 3.6
- Update pypi package classifiers
- Update docs
- Update CI test runners and codecov config
2020-10-19 17:26:45 +02:00
bastimeyer 8034b16063 chore: drop support for Python 2
- Bump Python version requirement to 3.5
- Remove unneeded compatibility dependencies
- Remove py2 warning from streamlink.session
- Update pypi package classifiers
- Update docs
- Remove universal bdist_wheel
- Update CI test runners and codecov config
2020-10-19 14:54:14 +02:00
back-to da4d885f9d docs/tests: remove python 3.4, use 3.8 and nightly for travis-ci
Python 3.4 has reached end-of-life.
https://www.python.org/downloads/release/python-3410/
2019-12-14 11:18:29 +01:00
Sebastian Meyer e96c725cb5 Build additional "streamlinkw" launcher on Windows (#2326)
* Build additional "streamlinkw" launcher on Windows

1/2: Windows installer (using a pre-release version of pynsist)

* Build additional "streamlinkw" launcher on Windows

2/2: Windows specific wheels
2019-03-06 17:34:16 -08:00
beardypig ae97399c8a
setup: update requests to latest version and set urllib3 to match 2019-01-03 17:38:44 +01:00
beardypig a14f170a04 sdist and wheel release fixes (#1758)
* build: fix for universal wheel on python 2.7

* release: fix build order for deploys

The script to build the sdist and wheel packages is run before the
script that uploads them to PyPI. The sdist script doesn't clean up
the environment, but extra prune options have been added to the
MANIFEST.in file (thanks @back-to).

* build: ensure twine/wheel up-to-date and upload sdist/whl separately
2018-06-07 18:01:16 -07:00
beardypig c1489782cf MPEG DASH Support (initial) (#1637)
* stream.dash: parser for dash manifest files

* stream.dash: stream player for dash with plugin to support dash:// prefixed urls

* cli.main: make sure that streams are closed on errors

* stream.dash: fix some parsing bugs

* stream.dash: tidy up the segment number generation

* plugins.dash: wip segment timeline

* stream.dash: update to segment timeline parsing

* stream.dash: py3 support

* stream.dash: raise an error for DRM protected streams

* stream.dash: fixes for timescaling and some segment templates

* docs: add DASHStream to docs with other Stream classes

* dash: fix for video only stream

* plugins.dash: fix bug where all URLs were matched

* stream.dash: fix issue with manifest reload

* plugin.dash: add tests and fix a couple of bugs found in testing

* stream.dash: add some tests to cover the DASHStream classes

* WIP: audio only streams

* add some debugging for threads and remove the thread joins

* dash: startNumber should default to 1

* dash: follow redirects to get the base url

* dash: fix bool parser, and segment template parser

* dash: fixed some issues...

...with some segment templates, as well as improving the presentation
delay handling

* dash: add a back-off for checking for manifest changes

* dash: fix broken tests

* dash: incomplete support for Segment@r

* dash: fixed audio/video sync issue

Added a `copyts` option to the FFMPEG muxer class so that the timestamps
given in the source files are maintained, this appears to fix the a/v
sync issues.

NB. The timestamp can get weird, but that's how it is :)

* dash: support for Time _and_ Number in segment timeline

* tests: add some dash parser tests + a little refactor

* tests: add dash to built in plugins

* tests: more coverage of dash_parser

Added a new module for tests, `freezegun`, for mocking time.

* dash: fix for missing publishTime

* dash: update available_at times to be datetime

This should fix any timezone or leap-second issues, etc.

* fixed timing issue for 1tv.ru

* dash: fix availability timeline for segment timeline

* dash: flake8 tweaks

* dash: add a few debug logging messages
2018-05-30 12:30:38 -07:00
beardypig 639fbed74a Add the README file to the Python package (#1665)
* package: include README for PyPI page

PyPI supports Markdown for the long_description for packages now, we
should include the README.md so that the project page looks a bit nicer.

See https://pypi.org/project/streamlink/0.12.1/#description

* package: improve the list of classifiers

* setup: added some more links and the supported python versions

As suggested by @back-to
2018-05-28 16:15:37 -07:00
beardypig 416c8347b3 build: use versioneer to set the build number (#1413)
* build: use versioneer to set the build number

* build: update the deploy scripts to use versioneer

* release: update docs version and fix tarball version

* build: no need to install versioneer on travis, etc.
2018-05-13 22:18:52 -07:00
Charlie Drage 8641fd87d0 0.12.1 Release 2018-05-07 11:02:14 -04:00
Charlie Drage d9f40f70a2 0.12.0 Release 2018-05-07 08:17:01 -04:00
Charlie Drage 93e7423ccf 0.11.0 Release 2018-03-08 13:46:06 -05:00
Charlie Drage a8d22f15c7 0.10.0 Release 2018-01-23 12:46:06 -05:00
Charlie Drage e4fc612a3f 0.9.0 Release 2017-11-14 08:21:13 -05:00
beardypig 6f37c3a049 setup: fix PySocks module dependency
Include `PySocks` instead of `requests[socks]`, due to a pip bug.
Also include the `win-inet-pton` module for old versions of Python
on Windows.
2017-11-07 16:52:40 +00:00
Charlie Drage a1caf846f1 0.8.1 Release 2017-09-12 13:36:37 -04:00
beardypig 2e5558da8b cli: support for SOCKS proxies
Any proxy type that is supported by `requests` can be used.

For example, SOCKS proxies are support by `requests`, and can be used:
  - `--http-proxy "socks5://[user:password@]host:port"`
  - `--https-proxy "socks5://[user:password@]host:port"`
to set streamlink to use socks proxies for http and https.
2017-08-04 18:35:49 +01:00
Forrest 7317e4d899 Merge pull request #1117 from beardypig/vaughnlive-html5
plugins.vaughnlive: support for the new vaughnlive website layout
2017-08-02 18:20:51 -07:00
beardypig 0f35b9b261 Resolve InsecurePlatformWarnings for older Python2.7 versions
This should resolve the issues some people are having with HTTPS
websites when using older versions of Python 2.7. As best I can tell the
any version before 2.7.10 is affected.
2017-07-27 16:08:52 +01:00
beardypig 6ab447ceea plugins.vaughnlive: support for the new vaughnlive website layout
Supports the new vaughnlive websockets API for both RTMP and HLS
streams. A new dependency is added to support this `websocket-client`.
2017-07-26 16:07:57 +01:00
Charlie Drage 7c2996f1bf 0.7.0 Release 2017-06-30 08:04:07 -04:00
beardypig e386cfbc5e setup: exclude requests version 2.16 through 2.17.1 2017-05-30 12:05:59 +01:00
Charlie Drage 2338850a56 0.6.0 Release 2017-05-11 09:54:11 -04:00