nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix

pythonPackages.nplusone: init at 1.0.0

authored by

Matías Lang and committed by
Jon
d00a6904 cf86eb8a

+51
+49
pkgs/development/python-modules/nplusone/default.nix
··· 1 + { blinker, buildPythonPackage, fetchFromGitHub, lib, isPy27, six, mock, pytest 2 + , webtest, pytestcov, pytest-django, pytest-pythonpath, flake8, sqlalchemy 3 + , flask_sqlalchemy, peewee }: 4 + 5 + buildPythonPackage rec { 6 + pname = "nplusone"; 7 + version = "1.0.0"; 8 + disabled = isPy27; 9 + 10 + src = fetchFromGitHub { 11 + owner = "jmcarp"; 12 + repo = "nplusone"; 13 + rev = "v${version}"; 14 + sha256 = "0qdwpvvg7dzmksz3vqkvb27n52lq5sa8i06m7idnj5xk2dgjkdxg"; 15 + }; 16 + 17 + # The tests assume the source code is in an nplusone/ directory. When using 18 + # the Nix sandbox, it will be in a source/ directory instead, making the 19 + # tests fail. 20 + prePatch = '' 21 + substituteInPlace tests/conftest.py \ 22 + --replace nplusone/tests/conftest source/tests/conftest 23 + ''; 24 + 25 + checkPhase = '' 26 + pytest tests/ 27 + ''; 28 + 29 + propagatedBuildInputs = [ six blinker ]; 30 + checkInputs = [ 31 + mock 32 + pytest 33 + webtest 34 + pytestcov 35 + pytest-django 36 + pytest-pythonpath 37 + flake8 38 + sqlalchemy 39 + flask_sqlalchemy 40 + peewee 41 + ]; 42 + 43 + meta = with lib; { 44 + description = "Detecting the n+1 queries problem in Python"; 45 + homepage = "https://github.com/jmcarp/nplusone"; 46 + maintainers = with maintainers; [ cript0nauta ]; 47 + license = licenses.mit; 48 + }; 49 + }
+2
pkgs/top-level/python-packages.nix
··· 2566 2566 2567 2567 mxnet = callPackage ../development/python-modules/mxnet { }; 2568 2568 2569 + nplusone = callPackage ../development/python-modules/nplusone { }; 2570 + 2569 2571 parsy = callPackage ../development/python-modules/parsy { }; 2570 2572 2571 2573 portalocker = callPackage ../development/python-modules/portalocker { };