Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
339 commits
Select commit Hold shift + click to select a range
3689638
chore(deps): update dependency google-auth to v1.31.0 (#204)
renovate-bot Jun 16, 2021
4f1f2e2
chore(deps): update dependency google-cloud-bigquery to v2.20.0 (#209)
renovate-bot Jun 16, 2021
d099309
chore(deps): update dependency google-auth to v1.32.0 (#215)
renovate-bot Jun 25, 2021
aefbf49
chore(deps): update dependency google-auth to v1.32.1 (#226)
renovate-bot Jul 1, 2021
c55828e
chore(deps): update dependency google-cloud-bigquery-storage to v2.5.…
renovate-bot Jul 1, 2021
b11fc7e
chore(deps): update dependency google-cloud-bigquery-storage to v2.6.…
renovate-bot Jul 9, 2021
520eaf9
docs: pandas DataFrame samples are more standalone (#224)
tswast Jul 13, 2021
a97acda
build(python): exit with success status if no samples found (#234)
gcf-owl-bot[bot] Jul 14, 2021
99ba827
chore(deps): update dependency google-auth to v1.33.0 (#236)
renovate-bot Jul 14, 2021
07c0feb
chore(deps): update dependency google-cloud-bigquery to v2.21.0 (#232)
renovate-bot Jul 16, 2021
1d8ccd1
feat: add Samples section to CONTRIBUTING.rst (#241)
gcf-owl-bot[bot] Jul 22, 2021
c3ffaf0
chore(deps): update dependency google-cloud-bigquery to v2.22.1 (#239)
renovate-bot Jul 27, 2021
dab9b53
chore(deps): update dependency google-auth to v1.33.1 (#243)
renovate-bot Jul 27, 2021
5b7d0bb
docs: remove duplicate code samples (#246)
tswast Jul 27, 2021
6abad5f
chore(deps): update dependency google-cloud-bigquery to v2.23.0 (#253)
renovate-bot Jul 28, 2021
e0bb621
chore(deps): update dependency google-auth to v1.34.0 (#252)
renovate-bot Jul 28, 2021
8626f7f
chore(deps): update dependency google-cloud-bigquery-storage to v2.6.…
renovate-bot Jul 28, 2021
5e4a9f6
chore(deps): update dependency pyarrow to v5 (#255)
renovate-bot Jul 28, 2021
d7d3c0f
chore(deps): update dependency google-cloud-bigquery to v2.23.1 (#254)
renovate-bot Jul 28, 2021
faa4523
chore(deps): update dependency google-cloud-bigquery to v2.23.2 (#256)
renovate-bot Jul 29, 2021
5e30f5b
chore: fix INSTALL_LIBRARY_FROM_SOURCE in noxfile.py (#270)
gcf-owl-bot[bot] Aug 11, 2021
3d133c0
chore: remove unused samples (#268)
tswast Aug 11, 2021
4b4125c
chore: drop mention of Python 2.7 from templates (#272)
gcf-owl-bot[bot] Aug 13, 2021
9058918
chore(deps): update dependency google-cloud-bigquery to v2.24.0 (#267)
renovate-bot Aug 13, 2021
f4c7f18
chore(deps): update dependency google-cloud-bigquery-storage to v2.6.…
renovate-bot Aug 13, 2021
1b4c791
chore(deps): update dependency google-auth to v1.35.0 (#274)
renovate-bot Aug 18, 2021
96c8276
chore(deps): update dependency google-cloud-bigquery to v2.24.1 (#276)
renovate-bot Aug 23, 2021
c0f1ea2
chore(deps): update dependency google-auth to v2 (#275)
renovate-bot Aug 23, 2021
6534f6e
chore(deps): update dependency google-auth to v2.0.2 (#289)
renovate-bot Sep 1, 2021
392cb3c
chore(deps): update dependency pytest to v6.2.5 (#288)
renovate-bot Sep 1, 2021
e7cd2df
chore(deps): update all dependencies (#291)
renovate-bot Sep 2, 2021
f3e84e7
feat: add `BigQueryWriteClient` where `append_rows` returns a helper …
tswast Sep 10, 2021
97ed04b
feat: add `AppendRowsStream` to use write API from v1 endpoint (#309)
tswast Sep 27, 2021
75bb82a
chore(deps): update all dependencies (#298)
renovate-bot Sep 27, 2021
4e0b763
chore(deps): update all dependencies (#313)
renovate-bot Sep 28, 2021
666dfe6
chore(deps): update dependency google-auth to v2.2.1 (#314)
renovate-bot Sep 29, 2021
3e4f7a5
chore: fail samples nox session if python version is missing (#316)
gcf-owl-bot[bot] Sep 30, 2021
05be3c2
chore(deps): update dependency google-cloud-bigquery to v2.28.0 (#317)
renovate-bot Oct 1, 2021
898e862
docs(samples): Add minimal sample to show Write API in pending mode (…
VeronicaWasson Oct 5, 2021
7f8e2ce
chore(deps): update dependency protobuf to v3.18.1 (#324)
renovate-bot Oct 6, 2021
d29e039
chore(deps): update dependency google-cloud-bigquery-storage to v2.9.…
renovate-bot Oct 7, 2021
44fb71b
chore(deps): update all dependencies (#327)
renovate-bot Oct 12, 2021
c8c15b2
chore(deps): update all dependencies (#335)
renovate-bot Nov 5, 2021
d572487
chore(python): fix formatting issue in noxfile.py.j2 (#331)
gcf-owl-bot[bot] Nov 5, 2021
0c76740
chore(deps): update all dependencies (#344)
renovate-bot Nov 5, 2021
da4c757
chore(deps): update dependency google-cloud-bigquery-storage to v2.10…
renovate-bot Nov 8, 2021
8afdf7a
chore(deps): update dependency google-cloud-bigquery-storage to v2.10…
renovate-bot Nov 16, 2021
6dd5615
chore(deps): update dependency pyarrow to v6.0.1 (#357)
renovate-bot Nov 18, 2021
59fc460
chore(deps): update all dependencies (#358)
renovate-bot Dec 3, 2021
85a762d
chore: update python-docs-samples link to main branch (#362)
gcf-owl-bot[bot] Dec 9, 2021
47cb3fd
chore(deps): update dependency google-cloud-testutils to v1.3.1 (#359)
renovate-bot Jan 6, 2022
ed937bd
chore(samples): Add check for tests in directory (#377)
gcf-owl-bot[bot] Jan 11, 2022
ba2c888
chore(python): Noxfile recognizes that tests can live in a folder (#383)
gcf-owl-bot[bot] Jan 19, 2022
c9160e6
doc: add region tags to `customer_record.proto` so it can be embedded…
tswast Feb 14, 2022
d46da7e
fix: remove bigquery.readonly auth scope (#394)
gcf-owl-bot[bot] Feb 18, 2022
deecfea
chore: use gapic-generator-python 0.63.4 (#397)
gcf-owl-bot[bot] Feb 25, 2022
dcb2bb7
chore: update copyright year to 2022 (#399)
gcf-owl-bot[bot] Feb 26, 2022
5057a2a
chore: Adding support for pytest-xdist and pytest-parallel (#406)
gcf-owl-bot[bot] Mar 4, 2022
acb4096
chore(deps): update all dependencies (#409)
renovate-bot Mar 7, 2022
2e7036a
chore(deps): update all dependencies (#410)
renovate-bot Mar 7, 2022
cfae702
chore(python): use black==22.3.0 (#417)
gcf-owl-bot[bot] Mar 29, 2022
d0f46ad
chore(deps): update all dependencies (#415)
renovate-bot Mar 30, 2022
3f97ea9
chore(deps): use === in requirements.txt for environment specific pin…
renovate-bot Mar 30, 2022
d189a18
chore(deps): update dependency google-cloud-bigquery to v2.34.3 (#422)
renovate-bot Mar 30, 2022
e051aa0
chore(deps): update all dependencies (#428)
renovate-bot Apr 3, 2022
92b42e5
chore(deps): update dependency tqdm to v4.64.0 (#430)
renovate-bot Apr 4, 2022
a3353b3
chore(deps): update dependency google-cloud-bigquery-storage to v2.13…
renovate-bot Apr 5, 2022
5bf4127
chore(deps): update dependency google-auth to v2.6.3 (#435)
renovate-bot Apr 7, 2022
a68de89
chore(deps): update dependency google-auth to v2.6.4 (#438)
renovate-bot Apr 12, 2022
b0d3970
chore: use gapic-generator-python 0.65.1 (#439)
gcf-owl-bot[bot] Apr 14, 2022
ec1115e
chore(deps): update dependency google-auth to v2.6.5 (#440)
renovate-bot Apr 15, 2022
618a38d
chore(python): add nox session to sort python imports (#441)
gcf-owl-bot[bot] Apr 21, 2022
11bb5ed
chore(deps): update all dependencies (#444)
renovate-bot Apr 22, 2022
646c543
chore(deps): update dependency pytest to v7.1.2 (#445)
renovate-bot Apr 25, 2022
c215af1
chore(deps): update dependency ipython to v8.3.0 (#447)
renovate-bot Apr 29, 2022
53bac97
chore: update all dependencies (#451)
renovate-bot May 9, 2022
73f2765
chore(deps): update all dependencies (#455)
renovate-bot Jun 7, 2022
2fa5736
fix: require python 3.7+ (#468)
gcf-owl-bot[bot] Jul 8, 2022
30eaa10
fix(deps): require google-api-core >= 2.8.0 (#465)
gcf-owl-bot[bot] Jul 8, 2022
4ae714a
chore(deps): update all dependencies (#476)
renovate-bot Aug 2, 2022
f2dc770
chore(deps): update all dependencies (#478)
renovate-bot Aug 9, 2022
5d14bbe
chore(deps): update all dependencies (#483)
renovate-bot Aug 9, 2022
5327c15
chore(deps): update dependency google-cloud-bigquery-storage to v2.14…
renovate-bot Aug 16, 2022
386c665
chore(deps): update dependency google-cloud-bigquery to v3.3.2 (#489)
renovate-bot Aug 23, 2022
e0a95d2
chore(deps): update dependency google-auth to v2.11.0 (#492)
renovate-bot Aug 23, 2022
5631376
chore(deps): update dependency pandas to v1.4.4 (#498)
renovate-bot Aug 31, 2022
b284768
chore(deps): update all dependencies (#504)
renovate-bot Sep 6, 2022
21e7cb5
chore: Bump gapic-generator-python version to 1.3.0 (#506)
gcf-owl-bot[bot] Sep 7, 2022
6763361
chore(deps): update dependency google-cloud-bigquery-storage to v2.15…
renovate-bot Sep 7, 2022
1404875
chore: detect samples tests in nested directories (#510)
gcf-owl-bot[bot] Sep 13, 2022
30f09e9
chore(deps): update dependency pandas to v1.5.0 (#511)
renovate-bot Sep 19, 2022
f3578da
chore(deps): update dependency google-cloud-bigquery-storage to v2.16…
renovate-bot Sep 20, 2022
cd03946
chore(deps): update dependency google-auth to v2.11.1 (#513)
renovate-bot Sep 20, 2022
3e18cb5
chore(deps): update dependency db-dtypes to v1.0.4 (#514)
renovate-bot Sep 21, 2022
8ade5e2
chore(deps): update dependency google-auth to v2.12.0 (#518)
renovate-bot Oct 3, 2022
1f1a8ac
chore(deps): update all dependencies (#521)
renovate-bot Oct 3, 2022
20b9c0e
chore(deps): update dependency google-cloud-bigquery-storage to v2.16…
renovate-bot Oct 10, 2022
be50547
chore(deps): update all dependencies (#525)
renovate-bot Oct 18, 2022
6c8726b
chore(deps): update dependency pandas to v1.5.1 (#526)
renovate-bot Oct 19, 2022
6b2ef9e
chore(deps): update dependency pytest to v7.2.0 (#527)
renovate-bot Oct 26, 2022
7f3a019
chore(python): drop flake8-import-order in samples noxfile (#535)
gcf-owl-bot[bot] Nov 26, 2022
7f8c205
feat: add missing_value_interpretations to AppendRowsRequest (#529)
gcf-owl-bot[bot] Nov 27, 2022
d4109d8
chore: move version to gapic_version.py (#537)
parthea Nov 30, 2022
b1788e9
chore(main): release 2.17.0 (#536)
release-please[bot] Dec 15, 2022
09b96e0
chore(python): add support for python 3.11 (#544)
gcf-owl-bot[bot] Jan 6, 2023
5f820f7
chore(deps): update all dependencies (#528)
renovate-bot Jan 9, 2023
bfd0707
chore(deps): update dependency ipython to v8.8.0 (#545)
renovate-bot Jan 9, 2023
22c5fbf
chore(deps): update dependency google-auth to v2.16.0 (#546)
renovate-bot Jan 9, 2023
0158b33
feat: Add support for python 3.11 (#547)
gcf-owl-bot[bot] Jan 10, 2023
2822c13
chore(main): release 2.18.0 (#548)
release-please[bot] Jan 10, 2023
a519419
chore(deps): update dependency google-cloud-bigquery-storage to v2.18…
renovate-bot Jan 10, 2023
91332a2
chore(deps): update dependency pytest to v7.2.1 (#550)
renovate-bot Jan 14, 2023
6bd9746
chore(deps): update dependency google-cloud-bigquery to v3.4.2 (#551)
renovate-bot Jan 18, 2023
a13a854
docs: Add documentation for enums (#553)
gcf-owl-bot[bot] Jan 20, 2023
266f4bd
chore(main): release 2.18.1 (#554)
release-please[bot] Jan 23, 2023
02c412d
chore(deps): update dependency pandas to v1.5.3 (#552)
renovate-bot Jan 23, 2023
5718ccc
chore(deps): update dependency google-cloud-bigquery-storage to v2.18…
renovate-bot Jan 24, 2023
72d4a7c
chore: Update gapic-generator-python to v1.8.2 (#557)
gcf-owl-bot[bot] Jan 25, 2023
4ba06c3
chore(deps): update all dependencies (#564)
renovate-bot Jan 27, 2023
92223f0
chore(deps): update dependency google-cloud-bigquery to v3.5.0 (#567)
renovate-bot Feb 2, 2023
044ac7f
chore(deps): update dependency ipython to v8.10.0 (#573)
renovate-bot Feb 15, 2023
8c4f524
chore(deps): bump ipython from 7.31.1 to 8.10.0 in /samples/to_datafr…
dependabot[bot] Feb 16, 2023
a1bb4b0
chore(deps): update all dependencies (#575)
renovate-bot Mar 1, 2023
f14cbee
chore(main): release 2.19.0 (#572)
release-please[bot] Mar 1, 2023
6b4eb25
chore(deps): update dependency google-cloud-bigquery-storage to v2.19…
renovate-bot Mar 1, 2023
43e6046
chore(deps): update all dependencies (#580)
renovate-bot Mar 4, 2023
df5a15a
chore(deps): update dependency google-cloud-bigquery to v3.7.0 (#582)
renovate-bot Mar 13, 2023
cc93f68
docs: Fix formatting of request arg in docstring (#586)
gcf-owl-bot[bot] Mar 23, 2023
a1878a5
chore(main): release 2.19.1 (#587)
release-please[bot] Mar 27, 2023
fb0bb39
chore(deps): update all dependencies (#585)
renovate-bot Mar 30, 2023
d2e4564
chore(deps): update all dependencies (#588)
renovate-bot Apr 6, 2023
56c1310
chore(deps): update all dependencies (#589)
renovate-bot Apr 18, 2023
6a1ac31
chore(deps): update dependency google-cloud-bigquery to v3.10.0 (#590)
renovate-bot Apr 19, 2023
7b63d5f
feat: add table sampling to ReadAPI v1 (#596)
gcf-owl-bot[bot] May 24, 2023
2971ec6
chore(main): release 2.20.0 (#597)
release-please[bot] May 31, 2023
b349b4b
chore(deps): update all dependencies (#591)
renovate-bot Jun 1, 2023
1e4c168
chore(deps): update all dependencies (#599)
renovate-bot Jun 1, 2023
f34f212
chore(deps): update all dependencies (#600)
renovate-bot Jun 22, 2023
3cf0b1d
feat: add estimated physical file sizes to ReadAPI v1 (#605)
gcf-owl-bot[bot] Jun 22, 2023
ed168a5
chore(main): release 2.21.0 (#607)
release-please[bot] Jul 5, 2023
c1bcc08
chore(deps): update dependency google-cloud-bigquery to v3.11.2 (#606)
renovate-bot Jul 5, 2023
ce5c36d
chore(deps): update all dependencies (#611)
renovate-bot Jul 5, 2023
900e974
feat: add ResourceExhausted to retryable error for Write API unary ca…
gcf-owl-bot[bot] Jul 6, 2023
e9ab0ca
chore(main): release 2.22.0 (#613)
release-please[bot] Jul 6, 2023
4787b47
chore(deps): update dependency google-cloud-bigquery-storage to v2.22…
renovate-bot Jul 6, 2023
794ebf2
chore: Update gapic-generator-python to v1.11.2 (#615)
gcf-owl-bot[bot] Jul 10, 2023
374608e
chore(deps): update dependency google-auth to v2.22.0 (#616)
renovate-bot Jul 12, 2023
37bad29
chore(deps): update dependency google-cloud-bigquery to v3.11.4 (#621)
renovate-bot Jul 22, 2023
f67698f
chore(deps): update dependency ipywidgets to v8.1.0 (#626)
renovate-bot Aug 1, 2023
725f413
chore(deps): update dependency tqdm to v4.65.1 (#631)
renovate-bot Aug 8, 2023
4e22048
chore(deps): update dependency tqdm to v4.65.2 (#632)
renovate-bot Aug 9, 2023
75e34de
chore(deps): update dependency tqdm to v4.66.0 (#633)
renovate-bot Aug 9, 2023
b38143d
chore(deps): update dependency tqdm to v4.66.1 (#634)
renovate-bot Aug 10, 2023
2dc8510
chore: [autoapprove] Update `black` and `isort` to latest versions (#…
gcf-owl-bot[bot] Oct 9, 2023
5b8e121
chore(deps): update dependency pyarrow to v14 [security] (#703)
renovate-bot Nov 10, 2023
c53660e
fix(samples): catch EOFError in quickstart (#708)
Linchin Nov 17, 2023
c289b54
chore(main): release 2.23.0 (#640)
release-please[bot] Nov 29, 2023
60745d7
chore(python): Add Python 3.12 (#710)
gcf-owl-bot[bot] Dec 1, 2023
6f1ff93
fix: use `retry_async` instead of `retry` in async client (#713)
gcf-owl-bot[bot] Dec 8, 2023
13806d0
chore(main): release 2.24.0 (#714)
release-please[bot] Dec 12, 2023
ba0cdf8
chore(deps): update all dependencies (#639)
renovate-bot Dec 14, 2023
0bd79e0
chore(deps): update all dependencies (#723)
renovate-bot Dec 14, 2023
8fdd6e5
feat: add ability to request compressed ReadRowsResponse rows (#728)
gcf-owl-bot[bot] Jan 12, 2024
c30a69e
feat: Add include_recaptcha_script for as a new action in firewall po…
gcf-owl-bot[bot] Mar 5, 2024
3f6f753
chore: sort imports (#761)
tswast Mar 19, 2024
3b023ab
chore: exclude sample-specific formatting from owlbot (#763)
tswast Mar 21, 2024
c837611
chore(deps): update all dependencies (#725)
renovate-bot Apr 5, 2024
9b1a629
fix: use triple equal for pinned requirements (#769)
Linchin Apr 11, 2024
210348e
chore(deps): update all dependencies (#766)
renovate-bot Apr 26, 2024
d5b0646
feat: add stream write samples for range (#780)
Linchin Apr 30, 2024
cbea008
chore(deps): update all dependencies (#778)
renovate-bot May 1, 2024
53e166c
chore(main): release 2.25.0 (#731)
release-please[bot] May 3, 2024
059c8c9
chore(deps): update all dependencies (#781)
renovate-bot May 6, 2024
fa040de
chore(deps): update dependency tqdm to v4.66.3 [security] (#783)
renovate-bot May 6, 2024
1416156
chore(deps): update all dependencies (#784)
renovate-bot May 16, 2024
20e4b99
chore(deps): update all dependencies (#787)
renovate-bot May 23, 2024
28fe731
chore(deps): update all dependencies (#789)
renovate-bot May 29, 2024
5f98494
chore(deps): update all dependencies (#790)
renovate-bot May 31, 2024
c612114
chore(deps): update all dependencies (#791)
renovate-bot Jun 3, 2024
b72202b
chore(deps): update all dependencies (#801)
renovate-bot Jul 17, 2024
8dd4cf2
chore(deps): update dependency pytest to v8.3.1 (#803)
renovate-bot Jul 22, 2024
e4cb504
chore(deps): update dependency pytest to v8.3.2 (#805)
renovate-bot Jul 29, 2024
bae1244
chore(deps): update dependency tqdm to v4.66.5 (#807)
renovate-bot Aug 13, 2024
22177d4
chore(deps): update all dependencies (#809)
renovate-bot Aug 13, 2024
d774939
feat: Add BigQuery Metastore Partition Service API version v1alpha (#…
gcf-owl-bot[bot] Aug 16, 2024
11a5ffc
chore(deps): update all dependencies (#813)
renovate-bot Aug 22, 2024
ad59836
chore(deps): update all dependencies (#816)
renovate-bot Aug 23, 2024
409ead8
feat: Add BigQuery Metastore Partition Service API version v1alpha (#…
gcf-owl-bot[bot] Sep 4, 2024
9cf73bc
chore(main): release 2.26.0 (#811)
release-please[bot] Sep 4, 2024
b233a54
chore(deps): update all dependencies (#823)
renovate-bot Sep 10, 2024
12cce4c
chore(deps): update all dependencies (#825)
renovate-bot Sep 10, 2024
2a24061
fix: Increase method timeout to 240s for BigQuery Metastore Partition…
gcf-owl-bot[bot] Sep 20, 2024
751c61d
build(deps): bump ipython from 7.31.1 to 8.10.0 in /samples/to_datafr…
dependabot[bot] Oct 1, 2024
4485a44
chore(main): release 2.27.0 (#831)
release-please[bot] Oct 14, 2024
303f1a2
build: use multiScm for Kokoro release builds (#844)
gcf-owl-bot[bot] Nov 13, 2024
0fc6e4e
chore(deps): update all dependencies (#843)
renovate-bot Nov 15, 2024
acc684a
fix: Disable universe-domain validation (#839)
gcf-owl-bot[bot] Nov 15, 2024
2bb2f7f
chore(deps): update all dependencies (#847)
renovate-bot Nov 19, 2024
40e6142
chore(deps): update all dependencies (#850)
renovate-bot Nov 26, 2024
2f99ebf
chore(deps): update all dependencies (#851)
renovate-bot Dec 2, 2024
3fc6aa9
chore(deps): update all dependencies (#852)
renovate-bot Dec 3, 2024
3d958cb
feat: Add support for opt-in debug logging (#855)
gcf-owl-bot[bot] Dec 12, 2024
7bea80c
chore(deps): update all dependencies (#854)
renovate-bot Dec 12, 2024
87618ca
chore(deps): update all dependencies (#856)
renovate-bot Dec 17, 2024
96c1d8d
chore(deps): update all dependencies (#858)
renovate-bot Jan 3, 2025
16ec227
chore(deps): update all dependencies (#866)
renovate-bot Jan 28, 2025
698e6ba
chore(main): release 2.28.0 (#848)
release-please[bot] Feb 4, 2025
d51706e
chore(deps): update all dependencies (#880)
renovate-bot Feb 4, 2025
bc96dfa
chore(deps): update all dependencies (#881)
renovate-bot Feb 11, 2025
5dc9430
feat: Add REST Interceptors which support reading metadata (#884)
gcf-owl-bot[bot] Feb 11, 2025
5583473
chore(deps): update dependency pyarrow to v19.0.1 (#894)
renovate-bot Feb 20, 2025
30cad98
chore(deps): update all dependencies (#898)
renovate-bot Feb 28, 2025
f230168
chore(deps): update all dependencies (#900)
renovate-bot Mar 4, 2025
62af9c3
chore(deps): update all dependencies (#903)
renovate-bot Mar 11, 2025
47a8fce
chore(main): release 2.29.0 (#887)
release-please[bot] Mar 11, 2025
3efdde6
chore(deps): update all dependencies (#908)
renovate-bot Mar 13, 2025
4419e67
chore(main): release 2.29.1 (#910)
release-please[bot] Mar 13, 2025
68b2ae7
chore: Update gapic-generator-python to 1.23.6 (#917)
gcf-owl-bot[bot] Mar 19, 2025
741fada
feat: sample for AppendRowsStream with Arrow (#915)
Linchin Mar 25, 2025
be9a81b
chore(main): release 2.30.0 (#914)
release-please[bot] Mar 25, 2025
0cc8bf3
chore(deps): update all dependencies (#912)
renovate-bot Mar 27, 2025
b30d9ee
test: make pyarrow sample less flaky (#919)
Linchin Mar 31, 2025
b580b7f
chore(deps): update all dependencies (#920)
renovate-bot Apr 3, 2025
fb44860
chore: Update gapic-generator-python to 1.24.1 (#924)
gcf-owl-bot[bot] Apr 21, 2025
03272ac
chore(main): release 2.31.0 (#925)
release-please[bot] Apr 23, 2025
470bc21
feat: Add BigQuery Metastore Partition Service API version v1beta (#941)
gcf-owl-bot[bot] May 1, 2025
c90da02
chore(deps): update all dependencies (#922)
renovate-bot May 6, 2025
d44d4cb
chore(deps): update all dependencies (#943)
renovate-bot May 12, 2025
95bace7
chore(deps): update all dependencies (#945)
renovate-bot May 22, 2025
e2b3376
fix: separate create_stream() in pyarrow sample (#946)
Linchin May 27, 2025
c4e3e3a
chore(main): release 2.32.0 (#942)
release-please[bot] May 28, 2025
8d23934
chore(deps): update all dependencies (#947)
renovate-bot May 30, 2025
5ed1b37
feat: Add support for CMEK, runtime controls, and PSC-I to Reasoning …
gcf-owl-bot[bot] Aug 18, 2025
a7a9666
chore(deps): update all dependencies (#967)
renovate-bot Aug 18, 2025
e6210fa
chore(deps): update dependency google-cloud-bigquery to v3.35.1 (#971)
renovate-bot Aug 18, 2025
077f941
Merge remote-tracking branch 'migration/main' into bqs-samples
Linchin Aug 18, 2025
61393fa
add headers
Linchin Aug 21, 2025
8ae82b0
delete generated samples
Linchin Aug 21, 2025
385314d
delete AUTHORING_GUIDE.md and CONTRIBUTING.md
Linchin Aug 21, 2025
34969f5
force tests to fail
Linchin Aug 27, 2025
92a483c
remove force fail code
Linchin Aug 27, 2025
b3777a7
add noxfile_config.py
Linchin Aug 27, 2025
fea315c
add noxfile_config.py to subfolders
Linchin Aug 27, 2025
a4646c4
add tests for python 3.7 and 3.8
Linchin Aug 27, 2025
d944ca9
delete noxfile.py in each subfolder
Linchin Aug 27, 2025
93ee955
delete noxfile.py in the bqstorage root folder
Linchin Aug 27, 2025
f8fa57a
fix some lint errors
Linchin Aug 27, 2025
b8f758a
lint
Linchin Aug 27, 2025
095c552
fix all lint!
Linchin Aug 27, 2025
8e8eeb4
add dependency to fix test failure
Linchin Aug 28, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Empty file added bigquery_storage/__init__.py
Empty file.
46 changes: 46 additions & 0 deletions bigquery_storage/conftest.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

import datetime
import os
import random
from typing import Generator

from google.cloud import bigquery

import pytest


@pytest.fixture(scope="session")
def project_id() -> str:
return os.environ["GOOGLE_CLOUD_PROJECT"]


@pytest.fixture(scope="session")
def dataset(project_id: str) -> Generator[bigquery.Dataset, None, None]:
client = bigquery.Client()

# Add a random suffix to dataset name to avoid conflict, because we run
# a samples test on each supported Python version almost at the same time.
dataset_time = datetime.datetime.now().strftime("%y%m%d_%H%M%S")
suffix = f"_{(random.randint(0, 99)):02d}"
dataset_name = "samples_tests_" + dataset_time + suffix

dataset_id = "{}.{}".format(project_id, dataset_name)
dataset = bigquery.Dataset(dataset_id)
dataset.location = "us-east7"
created_dataset = client.create_dataset(dataset)
yield created_dataset

client.delete_dataset(created_dataset, delete_contents=True)
15 changes: 15 additions & 0 deletions bigquery_storage/pyarrow/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# -*- coding: utf-8 -*-
#
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
224 changes: 224 additions & 0 deletions bigquery_storage/pyarrow/append_rows_with_arrow.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,224 @@
# -*- coding: utf-8 -*-
#
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from concurrent.futures import Future
import datetime
import decimal
from typing import Iterable

from google.cloud import bigquery
from google.cloud import bigquery_storage_v1
from google.cloud.bigquery import enums
from google.cloud.bigquery_storage_v1 import types as gapic_types
from google.cloud.bigquery_storage_v1.writer import AppendRowsStream
import pandas as pd
import pyarrow as pa


TABLE_LENGTH = 100_000

BQ_SCHEMA = [
bigquery.SchemaField("bool_col", enums.SqlTypeNames.BOOLEAN),
bigquery.SchemaField("int64_col", enums.SqlTypeNames.INT64),
bigquery.SchemaField("float64_col", enums.SqlTypeNames.FLOAT64),
bigquery.SchemaField("numeric_col", enums.SqlTypeNames.NUMERIC),
bigquery.SchemaField("bignumeric_col", enums.SqlTypeNames.BIGNUMERIC),
bigquery.SchemaField("string_col", enums.SqlTypeNames.STRING),
bigquery.SchemaField("bytes_col", enums.SqlTypeNames.BYTES),
bigquery.SchemaField("date_col", enums.SqlTypeNames.DATE),
bigquery.SchemaField("datetime_col", enums.SqlTypeNames.DATETIME),
bigquery.SchemaField("time_col", enums.SqlTypeNames.TIME),
bigquery.SchemaField("timestamp_col", enums.SqlTypeNames.TIMESTAMP),
bigquery.SchemaField("geography_col", enums.SqlTypeNames.GEOGRAPHY),
bigquery.SchemaField(
"range_date_col", enums.SqlTypeNames.RANGE, range_element_type="DATE"
),
bigquery.SchemaField(
"range_datetime_col",
enums.SqlTypeNames.RANGE,
range_element_type="DATETIME",
),
bigquery.SchemaField(
"range_timestamp_col",
enums.SqlTypeNames.RANGE,
range_element_type="TIMESTAMP",
),
]

PYARROW_SCHEMA = pa.schema(
[
pa.field("bool_col", pa.bool_()),
pa.field("int64_col", pa.int64()),
pa.field("float64_col", pa.float64()),
pa.field("numeric_col", pa.decimal128(38, scale=9)),
pa.field("bignumeric_col", pa.decimal256(76, scale=38)),
pa.field("string_col", pa.string()),
pa.field("bytes_col", pa.binary()),
pa.field("date_col", pa.date32()),
pa.field("datetime_col", pa.timestamp("us")),
pa.field("time_col", pa.time64("us")),
pa.field("timestamp_col", pa.timestamp("us")),
pa.field("geography_col", pa.string()),
pa.field(
"range_date_col",
pa.struct([("start", pa.date32()), ("end", pa.date32())]),
),
pa.field(
"range_datetime_col",
pa.struct([("start", pa.timestamp("us")), ("end", pa.timestamp("us"))]),
),
pa.field(
"range_timestamp_col",
pa.struct([("start", pa.timestamp("us")), ("end", pa.timestamp("us"))]),
),
]
)


def bqstorage_write_client() -> bigquery_storage_v1.BigQueryWriteClient:
return bigquery_storage_v1.BigQueryWriteClient()


def make_table(project_id: str, dataset_id: str, bq_client: bigquery.Client) -> bigquery.Table:
table_id = "append_rows_w_arrow_test"
table_id_full = f"{project_id}.{dataset_id}.{table_id}"
bq_table = bigquery.Table(table_id_full, schema=BQ_SCHEMA)
created_table = bq_client.create_table(bq_table)

return created_table


def create_stream(bqstorage_write_client: bigquery_storage_v1.BigQueryWriteClient, table: bigquery.Table) -> AppendRowsStream:
stream_name = f"projects/{table.project}/datasets/{table.dataset_id}/tables/{table.table_id}/_default"
request_template = gapic_types.AppendRowsRequest()
request_template.write_stream = stream_name

# Add schema to the template.
arrow_data = gapic_types.AppendRowsRequest.ArrowData()
arrow_data.writer_schema.serialized_schema = PYARROW_SCHEMA.serialize().to_pybytes()
request_template.arrow_rows = arrow_data

append_rows_stream = AppendRowsStream(
bqstorage_write_client,
request_template,
)
return append_rows_stream


def generate_pyarrow_table(num_rows: int = TABLE_LENGTH) -> pa.Table:
date_1 = datetime.date(2020, 10, 1)
date_2 = datetime.date(2021, 10, 1)

datetime_1 = datetime.datetime(2016, 12, 3, 14, 11, 27, 123456)
datetime_2 = datetime.datetime(2017, 12, 3, 14, 11, 27, 123456)

timestamp_1 = datetime.datetime(
1999, 12, 31, 23, 59, 59, 999999, tzinfo=datetime.timezone.utc
)
timestamp_2 = datetime.datetime(
2000, 12, 31, 23, 59, 59, 999999, tzinfo=datetime.timezone.utc
)

# Pandas Dataframe.
rows = []
for i in range(num_rows):
row = {
"bool_col": True,
"int64_col": i,
"float64_col": float(i),
"numeric_col": decimal.Decimal("0.000000001"),
"bignumeric_col": decimal.Decimal("0.1234567891"),
"string_col": "data as string",
"bytes_col": str.encode("data in bytes"),
"date_col": datetime.date(2019, 5, 10),
"datetime_col": datetime_1,
"time_col": datetime.time(23, 59, 59, 999999),
"timestamp_col": timestamp_1,
"geography_col": "POINT(-121 41)",
"range_date_col": {"start": date_1, "end": date_2},
"range_datetime_col": {"start": datetime_1, "end": datetime_2},
"range_timestamp_col": {"start": timestamp_1, "end": timestamp_2},
}
rows.append(row)
df = pd.DataFrame(rows)

# Dataframe to PyArrow Table.
table = pa.Table.from_pandas(df, schema=PYARROW_SCHEMA)

return table


def generate_write_requests(
pyarrow_table: pa.Table,
) -> Iterable[gapic_types.AppendRowsRequest]:
# Determine max_chunksize of the record batches. Because max size of
# AppendRowsRequest is 10 MB, we need to split the table if it's too big.
# See: https://cloud.google.com/bigquery/docs/reference/storage/rpc/google.cloud.bigquery.storage.v1#appendrowsrequest
max_request_bytes = 10 * 2**20 # 10 MB
chunk_num = int(pyarrow_table.nbytes / max_request_bytes) + 1
chunk_size = int(pyarrow_table.num_rows / chunk_num)

# Construct request(s).
for batch in pyarrow_table.to_batches(max_chunksize=chunk_size):
request = gapic_types.AppendRowsRequest()
request.arrow_rows.rows.serialized_record_batch = batch.serialize().to_pybytes()
yield request


def verify_result(
client: bigquery.Client, table: bigquery.Table, futures: "list[Future]"
) -> None:
bq_table = client.get_table(table)

# Verify table schema.
assert bq_table.schema == BQ_SCHEMA

# Verify table size.
query = client.query(f"SELECT COUNT(1) FROM `{bq_table}`;")
query_result = query.result().to_dataframe()

# There might be extra rows due to retries.
assert query_result.iloc[0, 0] >= TABLE_LENGTH

# Verify that table was split into multiple requests.
assert len(futures) == 2


def main(project_id: str, dataset: bigquery.Dataset) -> None:
# Initialize clients.
write_client = bqstorage_write_client()
bq_client = bigquery.Client()

# Create BigQuery table.
bq_table = make_table(project_id, dataset.dataset_id, bq_client)

# Generate local PyArrow table.
pa_table = generate_pyarrow_table()

# Convert PyArrow table to Protobuf requests.
requests = generate_write_requests(pa_table)

# Create writing stream to the BigQuery table.
stream = create_stream(write_client, bq_table)

# Send requests.
futures = []
for request in requests:
future = stream.send(request)
futures.append(future)
future.result() # Optional, will block until writing is complete.

# Verify results.
verify_result(bq_client, bq_table, futures)
21 changes: 21 additions & 0 deletions bigquery_storage/pyarrow/append_rows_with_arrow_test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

from google.cloud import bigquery

from . import append_rows_with_arrow


def test_append_rows_with_arrow(project_id: str, dataset: bigquery.Dataset) -> None:
append_rows_with_arrow.main(project_id, dataset)
42 changes: 42 additions & 0 deletions bigquery_storage/pyarrow/noxfile_config.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You maye obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# Default TEST_CONFIG_OVERRIDE for python repos.

# You can copy this file into your directory, then it will be imported from
# the noxfile.py.

# The source of truth:
# https://github.com/GoogleCloudPlatform/python-docs-samples/blob/main/noxfile_config.py

TEST_CONFIG_OVERRIDE = {
# You can opt out from the test for specific Python versions.
"ignored_versions": ["2.7"],
# Old samples are opted out of enforcing Python type hints
# All new samples should feature them
"enforce_type_hints": True,
# An envvar key for determining the project id to use. Change it
# to 'BUILD_SPECIFIC_GCLOUD_PROJECT' if you want to opt in using a
# build specific Cloud project. You can also use your own string
# to use your own Cloud project.
"gcloud_project_env": "GOOGLE_CLOUD_PROJECT",
# 'gcloud_project_env': 'BUILD_SPECIFIC_GCLOUD_PROJECT',
# If you need to use a specific version of pip,
# change pip_version_override to the string representation
# of the version number, for example, "20.2.4"
"pip_version_override": None,
# A dictionary you want to inject into your test. Don't put any
# secrets here. These values will override predefined values.
"envs": {},
}
3 changes: 3 additions & 0 deletions bigquery_storage/pyarrow/requirements-test.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
pytest===7.4.3; python_version == '3.7'
pytest===8.3.5; python_version == '3.8'
pytest==8.4.1; python_version >= '3.9'
5 changes: 5 additions & 0 deletions bigquery_storage/pyarrow/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
db_dtypes
google-cloud-bigquery
google-cloud-bigquery-storage
pandas
pyarrow
15 changes: 15 additions & 0 deletions bigquery_storage/quickstart/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# -*- coding: utf-8 -*-
#
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
Loading