Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / duckdb-engine / default.nix
blob955334bdf283db93c98755b48bf9a231399ee9cf
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , pytestCheckHook
5 , pythonOlder
6 , duckdb
7 , hypothesis
8 , ipython-sql
9 , poetry-core
10 , snapshottest
11 , sqlalchemy
12 , typing-extensions
15 buildPythonPackage rec {
16   pname = "duckdb-engine";
17   version = "0.11.2";
18   pyproject = true;
20   disabled = pythonOlder "3.7";
22   src = fetchFromGitHub {
23     repo = "duckdb_engine";
24     owner = "Mause";
25     rev = "refs/tags/v${version}";
26     hash = "sha256-yW1gaZ0B6JNX98KzAxf146goniNmWnkMUmJRrScot1w=";
27   };
29   patches = [ ./remote_data.patch ];
31   nativeBuildInputs = [
32     poetry-core
33   ];
35   propagatedBuildInputs = [
36     duckdb
37     sqlalchemy
38   ];
40   preCheck = ''
41     export HOME="$(mktemp -d)"
42   '';
44   disabledTests = [
45     # this test tries to download the httpfs extension
46     "test_preload_extension"
47     "test_motherduck"
48     # test should be skipped based on sqlalchemy version but isn't and fails
49     "test_commit"
50     # rowcount no longer generates an attribute error.
51     "test_rowcount"
52   ];
54   nativeCheckInputs = [
55     pytestCheckHook
56     hypothesis
57     ipython-sql
58     # TODO(cpcloud): include pandas here when it supports sqlalchemy 2.0
59     snapshottest
60     typing-extensions
61   ];
63   pythonImportsCheck = [
64     "duckdb_engine"
65   ];
67   meta = with lib; {
68     description = "SQLAlchemy driver for duckdb";
69     homepage = "https://github.com/Mause/duckdb_engine";
70     changelog = "https://github.com/Mause/duckdb_engine/blob/v${version}/CHANGELOG.md";
71     license = licenses.mit;
72     maintainers = with maintainers; [ cpcloud ];
73   };