1{ lib
2, asyncssh
3, buildPythonPackage
4, dulwich
5, fetchFromGitHub
6, fsspec
7, funcy
8, GitPython
9, pathspec
10, pygit2
11, pygtrie
12, pythonOlder
13, setuptools
14}:
15
16buildPythonPackage rec {
17 pname = "scmrepo";
18 version = "0.1.3";
19 format = "pyproject";
20
21 disabled = pythonOlder "3.7";
22
23 src = fetchFromGitHub {
24 owner = "iterative";
25 repo = pname;
26 rev = "refs/tags/${version}";
27 hash = "sha256-YivsP5c0fnpm/0VCFfyH054LYAQbyEdH+wZTRxsCAY4=";
28 };
29
30 postPatch = ''
31 substituteInPlace setup.cfg \
32 --replace "asyncssh>=2.7.1,<2.9" "asyncssh>=2.7.1" \
33 --replace "pathspec>=0.9.0,<0.10.0" "pathspec"
34 '';
35
36 nativeBuildInputs = [
37 setuptools
38 ];
39
40 propagatedBuildInputs = [
41 asyncssh
42 dulwich
43 fsspec
44 funcy
45 GitPython
46 pathspec
47 pygit2
48 pygtrie
49 ];
50
51 # Requires a running Docker instance
52 doCheck = false;
53
54 pythonImportsCheck = [
55 "scmrepo"
56 ];
57
58 meta = with lib; {
59 description = "SCM wrapper and fsspec filesystem";
60 homepage = "https://github.com/iterative/scmrepo";
61 license = licenses.asl20;
62 maintainers = with maintainers; [ fab ];
63 };
64}