Merge pull request #170040 from SuperSandro2000/google-cloud-bigquery
This commit is contained in:
commit
09450ad530
4 changed files with 104 additions and 2 deletions
39
pkgs/development/python-modules/db-dtypes/default.nix
Normal file
39
pkgs/development/python-modules/db-dtypes/default.nix
Normal file
|
@ -0,0 +1,39 @@
|
|||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchPypi
|
||||
, numpy
|
||||
, packaging
|
||||
, pandas
|
||||
, pyarrow
|
||||
, pytestCheckHook
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "db-dtypes";
|
||||
version = "1.0.0";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "3070d1a8d86ff0b5d9b16f15c5fab9c18893c6b3d5723cd95ee397b169049454";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [
|
||||
numpy
|
||||
packaging
|
||||
pandas
|
||||
pyarrow
|
||||
];
|
||||
|
||||
checkInputs = [
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "db_dtypes" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Pandas Data Types for SQL systems (BigQuery, Spanner)";
|
||||
homepage = "https://github.com/googleapis/python-db-dtypes-pandas";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ SuperSandro2000 ];
|
||||
};
|
||||
}
|
|
@ -0,0 +1,48 @@
|
|||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchPypi
|
||||
, google-api-core
|
||||
, google-auth
|
||||
, google-cloud-bigquery
|
||||
, pytestCheckHook
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "google-cloud-bigquery-storage";
|
||||
version = "2.13.1";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "7a25148f635a04ca9ff568d47e64be275d3a4a3c90772524879e8f88f270d92d";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [
|
||||
google-api-core
|
||||
];
|
||||
|
||||
checkInputs = [
|
||||
google-auth
|
||||
google-cloud-bigquery
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
# dependency loop with google-cloud-bigquery
|
||||
doCheck = false;
|
||||
|
||||
preCheck = ''
|
||||
rm -r google
|
||||
'';
|
||||
|
||||
pythonImportsCheck = [
|
||||
"google.cloud.bigquery_storage"
|
||||
"google.cloud.bigquery_storage_v1"
|
||||
"google.cloud.bigquery_storage_v1beta2"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "BigQuery Storage API API client library";
|
||||
homepage = "https://github.com/googleapis/python-bigquery-storage";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ SuperSandro2000 ];
|
||||
};
|
||||
}
|
|
@ -2,7 +2,9 @@
|
|||
, buildPythonPackage
|
||||
, fetchPypi
|
||||
, pytestCheckHook
|
||||
, db-dtypes
|
||||
, freezegun
|
||||
, google-cloud-bigquery-storage
|
||||
, google-cloud-core
|
||||
, google-cloud-datacatalog
|
||||
, google-cloud-storage
|
||||
|
@ -27,13 +29,15 @@ buildPythonPackage rec {
|
|||
};
|
||||
|
||||
propagatedBuildInputs = [
|
||||
google-resumable-media
|
||||
google-cloud-core
|
||||
google-cloud-bigquery-storage
|
||||
google-resumable-media
|
||||
proto-plus
|
||||
pyarrow
|
||||
];
|
||||
|
||||
checkInputs = [
|
||||
db-dtypes
|
||||
freezegun
|
||||
google-cloud-testutils
|
||||
ipython
|
||||
|
@ -54,8 +58,8 @@ buildPythonPackage rec {
|
|||
# requires credentials
|
||||
"test_bigquery_magic"
|
||||
"TestBigQuery"
|
||||
"test_context_with_no_query_cache_from_context"
|
||||
"test_arrow_extension_types_same_for_storage_and_REST_APIs_894"
|
||||
"test_query_retry_539"
|
||||
"test_list_rows_empty_table"
|
||||
"test_list_rows_page_size"
|
||||
"test_list_rows_scalars"
|
||||
|
@ -75,6 +79,13 @@ buildPythonPackage rec {
|
|||
"test__initiate_resumable_upload_with_retry"
|
||||
];
|
||||
|
||||
disabledTestPaths = [
|
||||
# requires credentials
|
||||
"tests/system/test_query.py"
|
||||
"tests/system/test_job_retry.py"
|
||||
"tests/system/test_pandas.py"
|
||||
];
|
||||
|
||||
pythonImportsCheck = [
|
||||
"google.cloud.bigquery"
|
||||
"google.cloud.bigquery_v2"
|
||||
|
|
|
@ -2099,6 +2099,8 @@ in {
|
|||
|
||||
dbutils = callPackage ../development/python-modules/dbutils { };
|
||||
|
||||
db-dtypes = callPackage ../development/python-modules/db-dtypes { };
|
||||
|
||||
dcmstack = callPackage ../development/python-modules/dcmstack { };
|
||||
|
||||
ddt = callPackage ../development/python-modules/ddt { };
|
||||
|
@ -3443,6 +3445,8 @@ in {
|
|||
|
||||
google-cloud-bigquery-logging = callPackage ../development/python-modules/google-cloud-bigquery-logging { };
|
||||
|
||||
google-cloud-bigquery-storage = callPackage ../development/python-modules/google-cloud-bigquery-storage { };
|
||||
|
||||
google-cloud-bigtable = callPackage ../development/python-modules/google-cloud-bigtable { };
|
||||
|
||||
google-cloud-container = callPackage ../development/python-modules/google-cloud-container { };
|
||||
|
|
Loading…
Reference in a new issue