From 1372c7546f45e33d2ef523f7c642b39de5dc0296 Mon Sep 17 00:00:00 2001 From: Lily Foster Date: Fri, 29 Jul 2022 18:43:00 -0400 Subject: [PATCH] pythonPackages.oscpy: fix flaky tests --- pkgs/development/python-modules/oscpy/default.nix | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/oscpy/default.nix b/pkgs/development/python-modules/oscpy/default.nix index 07991a0fac7e..7b2be6ab778c 100644 --- a/pkgs/development/python-modules/oscpy/default.nix +++ b/pkgs/development/python-modules/oscpy/default.nix @@ -1,4 +1,4 @@ -{ lib, buildPythonPackage, fetchFromGitHub, pytestCheckHook }: +{ lib, buildPythonPackage, fetchFromGitHub, fetchpatch, pytestCheckHook }: buildPythonPackage rec { pname = "oscpy"; @@ -11,6 +11,15 @@ buildPythonPackage rec { hash = "sha256-Luj36JLgU9xbBMydeobyf98U5zs5VwWQOPGV7TPXQwA="; }; + patches = [ + # Fix flaky tests with kivy/oscpy#67 - https://github.com/kivy/oscpy/pull/67 + (fetchpatch { + name = "improve-reliability-of-test_intercept_errors.patch"; + url = "https://github.com/kivy/oscpy/commit/2bc114a97692aef28f8b84d52d0d5a41554a7d93.patch"; + hash = "sha256-iT7cB3ChWD1o0Zx7//Czkk8TaU1oTU1pRQWvPeIpeWY="; + }) + ]; + checkInputs = [ pytestCheckHook ]; pythonImportsCheck = [ "oscpy" ];