From 40c3bc3b0876f82b7ebf6816ab32a3c0c6e91133 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebasti=C3=A1n=20Mancilla?= <238528+smancill@users.noreply.github.com> Date: Wed, 24 Nov 2021 04:46:33 -0300 Subject: [PATCH] pytho3Packages.m3u8: use upstream patch (#147163) Follow up to 2b84c77b3e4 (python3Packages.m3u8: fix build on Hydra (x86_64-darwin), 2021-11-19), now with upstream patch. --- pkgs/development/python-modules/m3u8/default.nix | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/m3u8/default.nix b/pkgs/development/python-modules/m3u8/default.nix index bc2233cf0d29..e69bf61657fa 100644 --- a/pkgs/development/python-modules/m3u8/default.nix +++ b/pkgs/development/python-modules/m3u8/default.nix @@ -1,4 +1,4 @@ -{ lib, buildPythonPackage, fetchFromGitHub, requests, iso8601, bottle, pytestCheckHook }: +{ lib, buildPythonPackage, fetchFromGitHub, fetchpatch, requests, iso8601, bottle, pytestCheckHook }: buildPythonPackage rec { pname = "m3u8"; @@ -11,6 +11,14 @@ buildPythonPackage rec { sha256 = "sha256-EfHhmV2otEgEy2OVohS+DF7dk97GFdWZ4cFCERZBmlA="; }; + patches = [ + # Fix hardcoded /tmp dir (fix build on Hydra) + (fetchpatch { + url = "https://github.com/globocom/m3u8/commit/cf7ae5fda4681efcea796cd7c51c02f152c36009.patch"; + sha256 = "sha256-SEETpIJQddid8D//6DVrSGs/BqDeMOzufE0bBrm+/xY="; + }) + ]; + propagatedBuildInputs = [ requests iso8601 ]; checkInputs = [ bottle pytestCheckHook ]; @@ -21,11 +29,6 @@ buildPythonPackage rec { "tests/test_variant_m3u8.py" ]; - preCheck = '' - # Fix test on Hydra - substituteInPlace tests/test_model.py --replace "/tmp/d.m3u8" "$TMPDIR/d.m3u8" - ''; - meta = with lib; { homepage = "https://github.com/globocom/m3u8"; description = "Python m3u8 parser";