1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 mock,
6 pathlib-abc,
7 pytestCheckHook,
8 pythonOlder,
9 setuptools,
10 smart-open,
11 typer,
12}:
13
14buildPythonPackage rec {
15 pname = "pathy";
16 version = "0.11.0";
17 pyproject = true;
18
19 disabled = pythonOlder "3.8";
20
21 src = fetchPypi {
22 inherit pname version;
23 hash = "sha256-uz0OawuL92709jxxkeluCvLtZcj9tfoXSI+ch55jcG0=";
24 };
25
26 pythonRelaxDeps = [ "smart-open" ];
27
28 build-system = [ setuptools ];
29
30 dependencies = [
31 pathlib-abc
32 smart-open
33 typer
34 ];
35
36 nativeCheckInputs = [
37 mock
38 pytestCheckHook
39 ];
40
41 disabledTestPaths = [
42 # Exclude tests that require provider credentials
43 "pathy/_tests/test_clients.py"
44 "pathy/_tests/test_gcs.py"
45 "pathy/_tests/test_s3.py"
46 ];
47
48 pythonImportsCheck = [ "pathy" ];
49
50 meta = with lib; {
51 # https://github.com/justindujardin/pathy/issues/113
52 broken = pathlib-abc.version != "0.1.1";
53 description = "Path interface for local and cloud bucket storage";
54 mainProgram = "pathy";
55 homepage = "https://github.com/justindujardin/pathy";
56 license = licenses.asl20;
57 maintainers = with maintainers; [ melling ];
58 };
59}