Merge pull request #138201 from DeeUnderscore/streamlink-patch-tests
streamlink: patch tests for compatibility with Requests 2.26
This commit is contained in:
commit
2c2a20a207
1 changed files with 9 additions and 5 deletions
|
@ -2,6 +2,7 @@
|
|||
, python3Packages
|
||||
, rtmpdump
|
||||
, ffmpeg
|
||||
, fetchpatch
|
||||
}:
|
||||
|
||||
python3Packages.buildPythonApplication rec {
|
||||
|
@ -33,11 +34,14 @@ python3Packages.buildPythonApplication rec {
|
|||
ffmpeg
|
||||
];
|
||||
|
||||
# note that upstream currently uses requests 2.25.1 in Windows builds
|
||||
postPatch = ''
|
||||
substituteInPlace setup.py \
|
||||
--replace 'requests>=2.26.0,<3.0' 'requests'
|
||||
'';
|
||||
patches = [
|
||||
# Patch failing tests to expect correct Accept-Encoding as generated by Requests
|
||||
(fetchpatch {
|
||||
url = "https://github.com/streamlink/streamlink/commit/ae747a113199c119bced4613d33edcc67a222bb9.patch";
|
||||
includes = [ "tests/test_stream_json.py" ];
|
||||
sha256 = "sha256-KEgyWdh5DNgNktmLSvKQowUQO9p9Q7zP4NbCQJPNgKw=";
|
||||
})
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://streamlink.github.io/";
|
||||
|
|
Loading…
Reference in a new issue