biome: 1.9.2 -> 1.9.3 (#349335)
[NixPkgs.git] / pkgs / development / python-modules / csvw / default.nix
blobbe429844d13d665facff1cfc743636cc9f0a876d
2   lib,
3   buildPythonPackage,
4   fetchFromGitHub,
5   pythonAtLeast,
6   pythonOlder,
7   attrs,
8   isodate,
9   python-dateutil,
10   rfc3986,
11   uritemplate,
12   pytestCheckHook,
13   pytest-mock,
16 buildPythonPackage rec {
17   pname = "csvw";
18   version = "1.11.0";
19   format = "setuptools";
21   disabled = pythonOlder "3.6";
23   src = fetchFromGitHub {
24     owner = "cldf";
25     repo = "csvw";
26     rev = "v${version}";
27     sha256 = "1393xwqawaxsflbq62vks92vv4zch8p6dd1mdvdi7j4vvf0zljkg";
28   };
30   propagatedBuildInputs = [
31     attrs
32     isodate
33     python-dateutil
34     rfc3986
35     uritemplate
36   ];
38   nativeCheckInputs = [
39     pytestCheckHook
40     pytest-mock
41   ];
43   patchPhase = ''
44     substituteInPlace setup.cfg \
45       --replace "--cov" ""
46   '';
48   disabledTests =
49     [
50       # this test is flaky on darwin because it depends on the resolution of filesystem mtimes
51       # https://github.com/cldf/csvw/blob/45584ad63ff3002a9b3a8073607c1847c5cbac58/tests/test_db.py#L257
52       "test_write_file_exists"
53     ]
54     ++ lib.optionals (pythonAtLeast "3.10") [
55       # https://github.com/cldf/csvw/issues/58
56       "test_roundtrip_escapechar"
57       "test_escapequote_escapecharquotechar_final"
58       "test_doubleQuote"
59     ];
61   pythonImportsCheck = [ "csvw" ];
63   meta = with lib; {
64     description = "CSV on the Web";
65     homepage = "https://github.com/cldf/csvw";
66     license = licenses.asl20;
67     maintainers = [ ];
68   };