mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-27 01:13:05 +00:00
pythonPackages.debugpy: 1.0.0b12 -> 1.0.0
Also fixes the Python 2.7 build
This commit is contained in:
parent
e7fe577d98
commit
abfbca91e7
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user