Merge pull request #10906 from sjourdois/pygal

python: pygal: 2.0.8 -> 2.0.10
This commit is contained in:
Domen Kožar 2015-11-09 08:52:24 +01:00
commit 954b3b616d

View File

@ -9476,37 +9476,17 @@ let
preConfigure = "substituteInPlace setup.py --replace /usr/share usr/share"; preConfigure = "substituteInPlace setup.py --replace /usr/share usr/share";
}; };
pygal = buildPythonPackage ( rec { pygal = buildPythonPackage rec {
version = "2.0.8"; version = "2.0.10";
name = "pygal-${version}"; name = "pygal-${version}";
patchPhase = '' doCheck = !isPyPy; # one check fails with pypy
# Run tests in pygal dir
substituteInPlace setup.py \
--replace "self.test_args = []" \
"self.test_args = ['-x', 'build/lib/pygal']"
# Open unicode files during tests
substituteInPlace pygal/test/test_graph.py \
--replace "import sys" \
"import sys, io"
substituteInPlace pygal/test/test_graph.py \
--replace "open(file_name)" \
"io.open(file_name, encoding='utf-8')"
# Use explicit integers (for python 3.5)
substituteInPlace pygal/colors.py \
--replace "'#%x%x%x' % (r / 17, g / 17, b / 17)" \
"'#%x%x%x' % (r // 17, g // 17, b // 17)"
substituteInPlace pygal/colors.py \
--replace "'#%x%x%x%x' % (r / 17, g / 17, b / 17, a * 15)" \
"'#%x%x%x%x' % (r // 17, g // 17, b // 17, int(a * 15))"
substituteInPlace pygal/colors.py \
--replace "'#%02x%02x%02x%02x' % (r, g, b, a * 255)" \
"'#%02x%02x%02x%02x' % (r, g, b, int(a * 255))"
'';
src = pkgs.fetchurl { src = pkgs.fetchFromGitHub {
url = "https://github.com/Kozea/pygal/archive/${version}.tar.gz"; owner = "Kozea";
sha256 = "1lv8avn7pdlxks50sd58shpqnxybf3l79bggy32qnbqczk4j2s0b"; repo = "pygal";
rev = version;
sha256 = "1j7qjgraapvfc80yp8xcbddqrw8379gqi7pwkvfml3qcqm0z0d33";
}; };
buildInputs = with self; [ flask pyquery pytest ]; buildInputs = with self; [ flask pyquery pytest ];
@ -9516,9 +9496,9 @@ let
description = "Sexy and simple python charting"; description = "Sexy and simple python charting";
homepage = http://www.pygal.org; homepage = http://www.pygal.org;
license = licenses.lgpl3; license = licenses.lgpl3;
maintainers = with maintainers; [ sjourdois ];
}; };
}); };
pymysql = buildPythonPackage rec { pymysql = buildPythonPackage rec {
name = "pymysql-${version}"; name = "pymysql-${version}";