python312Packages.smartypants: fix tests and regex patterns

This commit is contained in:
Martin Weinelt
2024-02-24 03:19:58 +01:00
parent bc38c1274e
commit 876379f883
@@ -1,7 +1,9 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, fetchpatch2
, isPyPy
, setuptools
, docutils
, pygments
, pytestCheckHook
@@ -9,8 +11,9 @@
buildPythonPackage rec {
version = "2.0.1";
format = "setuptools";
pname = "smartypants";
pyproject = true;
disabled = isPyPy;
src = fetchFromGitHub {
@@ -20,6 +23,19 @@ buildPythonPackage rec {
sha256 = "00p1gnb9pzb3svdq3c5b9b332gsp50wrqqa39gj00m133zadanjp";
};
patches = [
(fetchpatch2 {
# https://github.com/leohemsted/smartypants.py/pull/21
name = "smartypants-3.12-compat.patch";
url = "https://github.com/leohemsted/smartypants.py/commit/ea46bf36343044a7a61ba3acce4a7f188d986ec5.patch";
hash = "sha256-9lsiiZKFFKHLy7j3y9ff4gt01szY+2AHpWPAKQgKwZg=";
})
];
nativeBuildInputs = [
setuptools
];
nativeCheckInputs = [
docutils
pygments