From 0bc9f75dc16442abab86abcbab67dfe885378f95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Forsman?= Date: Sun, 29 Oct 2017 14:32:12 +0100 Subject: [PATCH] pythonPackages.construct: move to python-modules/ --- .../python-modules/construct/default.nix | 27 ++++++++++++++++++ pkgs/top-level/python-packages.nix | 28 +------------------ 2 files changed, 28 insertions(+), 27 deletions(-) create mode 100644 pkgs/development/python-modules/construct/default.nix diff --git a/pkgs/development/python-modules/construct/default.nix b/pkgs/development/python-modules/construct/default.nix new file mode 100644 index 00000000000..1845d7ec94f --- /dev/null +++ b/pkgs/development/python-modules/construct/default.nix @@ -0,0 +1,27 @@ +{ stdenv, buildPythonPackage, fetchFromGitHub, six, pythonOlder }: + +buildPythonPackage rec { + name = "construct-${version}"; + version = "2.8.10"; + + src = fetchFromGitHub { + owner = "construct"; + repo = "construct"; + rev = "v${version}"; + sha256 = "1xfmmc5pihn3ql9f7blrciy06y2bwczqvkbcpvh96dmgqwc3wys3"; + }; + + propagatedBuildInputs = [ six ]; + + # Tests fail with the following error on Python 3.5+ + # TypeError: not all arguments converted during string formatting + doCheck = pythonOlder "3.5"; + + meta = with stdenv.lib; { + description = "Powerful declarative parser (and builder) for binary data"; + homepage = http://construct.readthedocs.org/; + license = licenses.mit; + platforms = platforms.linux; + maintainers = with maintainers; [ bjornfor ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 67ea140586d..472f84c274d 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -3044,33 +3044,7 @@ in { confluent-kafka = callPackage ../development/python-modules/confluent-kafka {}; - - construct = buildPythonPackage rec { - name = "construct-${version}"; - version = "2.8.10"; - - src = pkgs.fetchFromGitHub { - owner = "construct"; - repo = "construct"; - rev = "v${version}"; - sha256 = "1xfmmc5pihn3ql9f7blrciy06y2bwczqvkbcpvh96dmgqwc3wys3"; - }; - - propagatedBuildInputs = with self; [ six ]; - - # Tests fail with the following error on Python 3.5+ - # TypeError: not all arguments converted during string formatting - doCheck = pythonOlder "3.5"; - - meta = { - description = "Powerful declarative parser (and builder) for binary data"; - homepage = http://construct.readthedocs.org/; - license = licenses.mit; - platforms = platforms.linux; - maintainers = with maintainers; [ bjornfor ]; - }; - }; - + construct = callPackage ../development/python-modules/construct {}; consul = buildPythonPackage (rec { name = "python-consul-0.7.0";