about summary refs log tree commit diff
path: root/pkgs/development/python-modules/debugpy
diff options
context:
space:
mode:
authorMetaDark <kira.bruneau@gmail.com>2020-08-11 22:59:39 -0400
committerMetaDark <kira.bruneau@gmail.com>2020-10-01 01:02:45 -0400
commitabfbca91e70eb797a22f70697251662c339fc8de (patch)
tree99aa6225b8e67329da0138bbf79aa7a7319b76a3 /pkgs/development/python-modules/debugpy
parente7fe577d9803885d1191c6612b95c246cb605dde (diff)
pythonPackages.debugpy: 1.0.0b12 -> 1.0.0
Also fixes the Python 2.7 build
Diffstat (limited to 'pkgs/development/python-modules/debugpy')
-rw-r--r--pkgs/development/python-modules/debugpy/default.nix50
1 files changed, 38 insertions, 12 deletions
diff --git a/pkgs/development/python-modules/debugpy/default.nix b/pkgs/development/python-modules/debugpy/default.nix
index 2d11dee64a8bb..52f23f437a60a 100644
--- a/pkgs/development/python-modules/debugpy/default.nix
+++ b/pkgs/development/python-modules/debugpy/default.nix
@@ -1,19 +1,30 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
-, substituteAll, gdb
-, colorama, django, flask, gevent, psutil, pytest
-, pytest-timeout, pytest_xdist, requests
+{ lib
+, stdenv
+, buildPythonPackage
+, fetchFromGitHub
+, substituteAll
+, gdb
+, colorama
+, flask
+, psutil
+, pytest-timeout
+, pytest_xdist
+, pytestCheckHook
+, requests
 , isPy27
+, django
+, gevent
 }:
 
 buildPythonPackage rec {
   pname = "debugpy";
-  version = "1.0.0b12";
+  version = "1.0.0";
 
   src = fetchFromGitHub {
     owner = "Microsoft";
     repo = pname;
     rev = "v${version}";
-    sha256 = "0sz33aq5qldl7kh4qjf5w3d08l9s77ipcj4i9wfklj8f6vf9w1wh";
+    sha256 = "1cxwbq97n5pfmq0hji1ybbc6i1jg5bjy830dq23zqxbwxxwjx98m";
   };
 
   patches = [
@@ -49,16 +60,31 @@ buildPythonPackage rec {
   )'';
 
   checkInputs = [
-    colorama django flask gevent psutil pytest
-    pytest-timeout pytest_xdist requests
+    colorama
+    flask
+    psutil
+    pytest-timeout
+    pytest_xdist
+    pytestCheckHook
+    requests
+  ] ++ lib.optionals (!isPy27) [
+    django
+    gevent
   ];
 
   # Override default arguments in pytest.ini
-  checkPhase = "pytest --timeout 0 -n $NIX_BUILD_CORES"
-               # gevent fails to import zope.interface with Python 2.7
-               + stdenv.lib.optionalString isPy27 " -k 'not test_gevent'";
+  pytestFlagsArray = [ "--timeout=0" "-n=$NIX_BUILD_CORES" ];
 
-  meta = with stdenv.lib; {
+  disabledTests = lib.optionals isPy27 [
+    # django 1.11 is the last version to support Python 2.7
+    # and is no longer built in nixpkgs
+    "django"
+
+    # gevent fails to import zope.interface with Python 2.7
+    "gevent"
+  ];
+
+  meta = with lib; {
     description = "An implementation of the Debug Adapter Protocol for Python";
     homepage = "https://github.com/microsoft/debugpy";
     license = licenses.mit;