From 1e36af2854da5cb6ab48d1384c9985460c22d775 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Sun, 9 May 2021 11:21:19 -0400 Subject: [PATCH] python39Packages.random2: fix build --- pkgs/development/python-modules/random2/default.nix | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/pkgs/development/python-modules/random2/default.nix b/pkgs/development/python-modules/random2/default.nix index 6845a5707da7..cb84d32ef414 100644 --- a/pkgs/development/python-modules/random2/default.nix +++ b/pkgs/development/python-modules/random2/default.nix @@ -2,6 +2,7 @@ , buildPythonPackage , fetchPypi , isPyPy +, fetchpatch }: buildPythonPackage rec { @@ -15,6 +16,14 @@ buildPythonPackage rec { sha256 = "34ad30aac341039872401595df9ab2c9dc36d0b7c077db1cea9ade430ed1c007"; }; + patches = [ + # Patch test suite for python >= 3.9 + (fetchpatch { + url = "https://github.com/strichter/random2/pull/3/commits/1bac6355d9c65de847cc445d782c466778b94fbd.patch"; + sha256 = "064137pg1ilv3f9r10123lqbqz45070jca8pjjyp6gpfd0yk74pi"; + }) + ]; + meta = with lib; { homepage = "http://pypi.python.org/pypi/random2"; description = "Python 3 compatible Python 2 `random` Module";