about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/uncompyle6/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/uncompyle6/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/uncompyle6/default.nix39
1 files changed, 39 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/uncompyle6/default.nix b/nixpkgs/pkgs/development/python-modules/uncompyle6/default.nix
new file mode 100644
index 000000000000..4f8d461c87e2
--- /dev/null
+++ b/nixpkgs/pkgs/development/python-modules/uncompyle6/default.nix
@@ -0,0 +1,39 @@
+{ lib, stdenv
+, buildPythonPackage
+, fetchPypi
+, pythonAtLeast
+, spark_parser
+, xdis
+, nose
+, pytest
+, hypothesis
+, six
+}:
+
+buildPythonPackage rec {
+  pname = "uncompyle6";
+  version = "3.7.4";
+  disabled = pythonAtLeast "3.9"; # See: https://github.com/rocky/python-uncompyle6/issues/331
+
+  src = fetchPypi {
+    inherit pname version;
+    sha256 = "af8330861bf940e7a3ae0f06d129b8e645191a36bf73ca15ff51997a837d41f8";
+  };
+
+  checkInputs = [ nose pytest hypothesis six ];
+  propagatedBuildInputs = [ spark_parser xdis ];
+
+  # six import errors (yet it is supplied...)
+  checkPhase = ''
+    runHook preCheck
+    pytest ./pytest --ignore=pytest/test_function_call.py
+    runHook postCheck
+  '';
+
+  meta = with lib; {
+    description = "Python cross-version byte-code deparser";
+    homepage = "https://github.com/rocky/python-uncompyle6/";
+    license = licenses.gpl3;
+  };
+
+}