Unverified Commit 3c2441e5 authored by Marek Fajkus's avatar Marek Fajkus Committed by GitHub
Browse files

duckdb: 1.0.0 -> 1.1.1 (#341169)

parents 98dfa194 df3c93ce
Loading
Loading
Loading
Loading
+4 −5
Original line number Diff line number Diff line
@@ -45,11 +45,6 @@ stdenv.mkDerivation (finalAttrs: {
    "-DBUILD_UNITTESTS=ON"
  ];

  postInstall = ''
    mkdir -p $lib
    mv $out/lib $lib
  '';

  doInstallCheck = true;

  installCheckPhase =
@@ -98,6 +93,10 @@ stdenv.mkDerivation (finalAttrs: {
        # wants http connection
        "test/sql/copy/csv/recursive_query_csv.test"
        "test/sql/copy/csv/test_mixed_lines.test"
        "test/parquet/parquet_long_string_stats.test"
        "test/sql/attach/attach_remote.test"
        "test/sql/copy/csv/test_sniff_httpfs.test"
        "test/sql/httpfs/internal_issue_2490.test"
      ] ++ lib.optionals stdenv.hostPlatform.isAarch64 [
        "test/sql/aggregate/aggregates/test_kurtosis.test"
        "test/sql/aggregate/aggregates/test_skewness.test"
+3 −3
Original line number Diff line number Diff line
{
  "version": "1.0.0",
  "rev": "1f98600c2cf8722a6d2f2d805bb4af5e701319fc",
  "hash": "sha256-bzFxWv8+Ac8vZLd2OWJyu4T0/0dc7wykdOORMpx92Ic="
  "version": "1.1.1",
  "rev": "af39bd0dcf66876e09ac2a7c3baa28fe1b301151",
  "hash": "sha256-YPS3DqIYmFKXGkiQiU7/QKNNn7+YyavrA4uDenKuX2g="
}
+6 −6
Original line number Diff line number Diff line
@@ -12,6 +12,7 @@
  Security,
  SystemConfiguration,
  typing-extensions,
  pythonOlder,
}:

let
@@ -19,16 +20,16 @@ let
    name = "arrow-testing";
    owner = "apache";
    repo = "arrow-testing";
    rev = "5bab2f264a23f5af68f69ea93d24ef1e8e77fc88";
    hash = "sha256-Pxx8ohUpXb5u1995IvXmxQMqWiDJ+7LAll/AjQP7ph8=";
    rev = "4d209492d514c2d3cb2d392681b9aa00e6d8da1c";
    hash = "sha256-IkiCbuy0bWyClPZ4ZEdkEP7jFYLhM7RCuNLd6Lazd4o=";
  };

  parquet-testing = fetchFromGitHub {
    name = "parquet-testing";
    owner = "apache";
    repo = "parquet-testing";
    rev = "e13af117de7c4f0a4d9908ae3827b3ab119868f3";
    hash = "sha256-rVI9zyk9IRDlKv4u8BeMb0HRdWLfCpqOlYCeUdA7BB8=";
    rev = "50af3d8ce206990d81014b1862e5ce7380dc3e08";
    hash = "sha256-edyv/r5olkj09aHtm8LHZY0b3jUtLNUcufwI41qKYaY=";
  };
in

@@ -66,8 +67,7 @@ buildPythonPackage rec {

  dependencies = [
    pyarrow
    typing-extensions
  ];
  ] ++ lib.optionals (pythonOlder "3.13") [ typing-extensions ];

  nativeCheckInputs = [
    pytestCheckHook
+10 −0
Original line number Diff line number Diff line
@@ -5,6 +5,7 @@
  pytestCheckHook,
  pythonAtLeast,
  pythonOlder,
  python,
  duckdb,
  hypothesis,
  pandas,
@@ -63,6 +64,15 @@ buildPythonPackage rec {
    "duckdb_engine/tests/test_datatypes.py"
  ];

  disabledTests = [
    # incompatible with duckdb 1.1.1
    "test_with_cache"
  ] ++ lib.optionals (python.pythonVersion == "3.11") [
    # incompatible with duckdb 1.1.1
    "test_all_types_reflection"
    "test_nested_types"
  ];

  pythonImportsCheck = [ "duckdb_engine" ];

  meta = with lib; {
+129 −37
Original line number Diff line number Diff line
@@ -5,20 +5,19 @@
  pythonOlder,
  pytestCheckHook,
  atpublic,
  bidict,
  black,
  clickhouse-connect,
  dask,
  datafusion,
  db-dtypes,
  duckdb,
  fetchpatch,
  filelock,
  geopandas,
  google-cloud-bigquery,
  google-cloud-bigquery-storage,
  graphviz,
  hypothesis,
  multipledispatch,
  numpy,
  oracledb,
  packaging,
@@ -57,25 +56,24 @@
}:
let
  testBackends = [
    "datafusion"
    "duckdb"
    "pandas"
    "sqlite"
    "datafusion"
  ];

  ibisTestingData = fetchFromGitHub {
    name = "ibis-testing-data";
    owner = "ibis-project";
    repo = "testing-data";
    # https://github.com/ibis-project/ibis/blob/9.1.0/nix/overlay.nix#L20-L26
    rev = "6737d1cb5951cabaccd095a3ae62a93dbd11ecb9";
    hash = "sha256-MoVTZPWh4KVlrICYACrgfeLdl/fqoa1iweNg3zUtdrs=";
    # https://github.com/ibis-project/ibis/blob/9.5.0/nix/overlay.nix#L20-L26
    rev = "b26bd40cf29004372319df620c4bbe41420bb6f8";
    sha256 = "sha256-1fenQNQB+Q0pbb0cbK2S/UIwZDE4PXXG15MH3aVbyLU=";
  };
in

buildPythonPackage rec {
  pname = "ibis-framework";
  version = "9.1.0";
  version = "9.5.0";
  pyproject = true;

  disabled = pythonOlder "3.10";
@@ -85,9 +83,18 @@ buildPythonPackage rec {
    repo = "ibis";
    owner = "ibis-project";
    rev = "refs/tags/${version}";
    hash = "sha256-GmzmXzYMs7K7B//is3ZoD4muPAkb0tM56zFBbsA+NEo=";
    hash = "sha256-6ebw/E3jZFMHKqC5ZY//2Ke0NrklyoGp5JGKBfDxy40=";
  };

  patches = [
    # remove after the 10.0 release
    (fetchpatch {
      name = "ibis-framework-duckdb-1.1.1.patch";
      url = "https://github.com/ibis-project/ibis/commit/a54eceabac1d6592e9f6ab0ca7749e37a748c2ad.patch";
      hash = "sha256-j5BPYVqnEF9GQV5N3/VhFUCdsEwAIOQC0KfZ5LNBSRg=";
    })
  ];

  nativeBuildInputs = [
    poetry-core
    poetry-dynamic-versioning
@@ -98,16 +105,9 @@ buildPythonPackage rec {

  propagatedBuildInputs = [
    atpublic
    bidict
    multipledispatch
    numpy
    pandas
    parsy
    pyarrow
    pyarrow-hotfix
    python-dateutil
    pytz
    rich
    sqlglot
    toolz
    typing-extensions
@@ -124,13 +124,17 @@ buildPythonPackage rec {
    pytest-randomly
    pytest-snapshot
    pytest-timeout
    # this dependency is still needed due to use of strict markers and
    # `pytest.mark.xdist_group` in the ibis codebase
    pytest-xdist
  ] ++ lib.concatMap (name: optional-dependencies.${name}) testBackends;

  dontUsePytestXdist = true;

  pytestFlagsArray = [
    "--dist=loadgroup"
    "-m"
    "'${lib.concatStringsSep " or " testBackends} or core'"
    # tpcds and tpch are slow, so disable them
    "'not tpcds and not tpch and (${lib.concatStringsSep " or " testBackends} or core)'"
  ];

  disabledTests = [
@@ -142,6 +146,7 @@ buildPythonPackage rec {
    "test_register_sqlite"
    # requires network connection
    "test_s3_403_fallback"
    "test_hugging_face"
    # requires pytest 8.2+
    "test_roundtrip_delta"
  ];
@@ -172,44 +177,131 @@ buildPythonPackage rec {
      db-dtypes
      google-cloud-bigquery
      google-cloud-bigquery-storage
      pyarrow
      pyarrow-hotfix
      pydata-google-auth
      numpy
      pandas
      rich
    ];
    clickhouse = [ clickhouse-connect ];
    dask = [
      dask
      regex
      packaging
    clickhouse = [
      clickhouse-connect
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    datafusion = [
      datafusion
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    druid = [
      pydruid
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    duckdb = [
      duckdb
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    flink = [
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    datafusion = [ datafusion ];
    druid = [ pydruid ];
    duckdb = [ duckdb ];
    flink = [ ];
    geospatial = [
      geopandas
      shapely
    ];
    mssql = [ pyodbc ];
    mysql = [ pymysql ];
    mssql = [
      pyodbc
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    mysql = [
      pymysql
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    oracle = [
      oracledb
      packaging
    ];
    pandas = [
      regex
      packaging
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    polars = [
      polars
      packaging
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    postgres = [
      psycopg2
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    postgres = [ psycopg2 ];
    pyspark = [
      pyspark
      packaging
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    snowflake = [
      snowflake-connector-python
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    sqlite = [
      regex
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    trino = [
      trino-python-client
      pyarrow
      pyarrow-hotfix
      numpy
      pandas
      rich
    ];
    snowflake = [ snowflake-connector-python ];
    sqlite = [ regex ];
    trino = [ trino-python-client ];
    visualization = [ graphviz ];
    decompiler = [ black ];
    examples = [ pins ] ++ pins.optional-dependencies.gcs;
Loading