1{ stdenv, fetchurl, buildPythonPackage, pip, pytest, click, six, first
2, setuptools_scm, git, glibcLocales, mock }:
3
4buildPythonPackage rec {
5 pname = "pip-tools";
6 version = "2.0.2";
7 name = pname + "-" + version;
8
9 src = fetchurl {
10 url = "mirror://pypi/p/pip-tools/${name}.tar.gz";
11 sha256 = "f11fc3bf1d87a0b4a68d4d595f619814e2396e92d75d7bdd2500edbf002ea6de";
12 };
13
14 LC_ALL = "en_US.UTF-8";
15 checkInputs = [ pytest git glibcLocales mock ];
16 propagatedBuildInputs = [ pip click six first setuptools_scm ];
17
18 disabledTests = stdenv.lib.concatMapStringsSep " and " (s: "not " + s) [
19 # Depend on network tests:
20 "test_editable_package_vcs"
21 "test_generate_hashes_all_platforms"
22 "test_generate_hashes_without_interfering_with_each_other"
23 "test_realistic_complex_sub_dependencies"
24 "test_generate_hashes_with_editable"
25 "test_filter_pip_markes"
26 "test_get_hashes_local_repository_cache_miss"
27 # Expect specific version of "six":
28 "test_editable_package"
29 "test_input_file_without_extension"
30 "test_locally_available_editable_package_is_not_archived_in_cache_dir"
31 "test_no_candidates"
32 "test_no_candidates_pre"
33 ];
34
35 checkPhase = ''
36 export HOME=$(mktemp -d) VIRTUAL_ENV=1
37 py.test -k "${disabledTests}"
38 '';
39
40 meta = with stdenv.lib; {
41 description = "Keeps your pinned dependencies fresh";
42 homepage = https://github.com/jazzband/pip-tools/;
43 license = licenses.bsd3;
44 maintainers = with maintainers; [ zimbatm ];
45 };
46}