Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / db-dtypes / default.nix
bloba7fbfd1b378342279d027c3de245bf0700403729
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , fetchpatch
5 , numpy
6 , packaging
7 , pandas
8 , pyarrow
9 , pytestCheckHook
10 , pythonOlder
13 buildPythonPackage rec {
14   pname = "db-dtypes";
15   version = "1.1.1";
16   format = "setuptools";
18   disabled = pythonOlder "3.7";
20   src = fetchFromGitHub {
21     owner = "googleapis";
22     repo = "python-db-dtypes-pandas";
23     rev = "refs/tags/v${version}";
24     hash = "sha256-OAVHx/a4uupVGXSWN2/3uem9/4i+TUkzTX4kp0uLY44=";
25   };
27   patches = [
28     # on master branch, to be released as 1.1.2
29     (fetchpatch {
30       name = "xfail-tests-that-are-known-to-fail.patch";
31       url = "https://github.com/googleapis/python-db-dtypes-pandas/commit/4a56b766b0ccba900a555167863f1081a76c4c0d.patch";
32       hash = "sha256-ra1d8Vewvwhkr7PBHc3KM6IUCWsHxE+B7UP2duTgjew=";
33     })
34     # on master branch, to be released as 1.1.2
35     (fetchpatch {
36       name = "add-import-and-object-reference-due-to-upstream-changes.patch";
37       url = "https://github.com/googleapis/python-db-dtypes-pandas/commit/8a7b25f3e708df5cd32afcb702fe16130846b165.patch";
38       hash = "sha256-JVbhiOIr5gKMSQpIQ+DgIRqq8V5x5ClQhkQzAmIYqEU=";
39     })
40   ];
42   propagatedBuildInputs = [
43     numpy
44     packaging
45     pandas
46     pyarrow
47   ];
49   nativeCheckInputs = [
50     pytestCheckHook
51   ];
53   pythonImportsCheck = [
54     "db_dtypes"
55   ];
57   meta = with lib; {
58     description = "Pandas Data Types for SQL systems (BigQuery, Spanner)";
59     homepage = "https://github.com/googleapis/python-db-dtypes-pandas";
60     changelog = "https://github.com/googleapis/python-db-dtypes-pandas/blob/v${version}/CHANGELOG.md";
61     license = licenses.asl20;
62     maintainers = with maintainers; [ ];
63   };