Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
03400c4
feat: support transaction isolation level in dbapi (#1327)
olavloite Apr 2, 2025
b3c259d
fix: improve client-side regex statement parser (#1328)
olavloite Apr 3, 2025
3ac0f91
feat: add SQL statement for begin transaction isolation level (#1331)
olavloite Apr 14, 2025
beb33d2
chore(python): remove noxfile.py from templates (#1335)
gcf-owl-bot[bot] Apr 14, 2025
ca76108
feat: add sample for pre-split feature (#1333)
aksharauke Apr 22, 2025
a8f38cd
chore: sample fix with increased timeout (#1339)
harshachinta Apr 22, 2025
6ca9b43
feat: add interval type support (#1340)
rahul2393 Apr 28, 2025
9331146
chore(main): release 3.54.0 (#1330)
release-please[bot] Apr 28, 2025
e064474
fix: remove setup.cfg configuration for creating universal wheels (#1…
parthea Apr 29, 2025
3943885
fix: E2E tracing metadata append issue (#1357)
surbhigarg92 May 2, 2025
c55fb36
test: fix retry helpers currently causing flaky test failures (#1369)
olavloite May 5, 2025
aae8d61
fix: pass through kwargs in dbapi connect (#1368)
olavloite May 6, 2025
e53eaa2
build: reduce build time (#1370)
olavloite May 6, 2025
686bda6
chore(x-goog-request-id): commit testing scaffold (#1366)
odeke-em May 7, 2025
064d9dc
feat: support fine-grained permissions database roles in connect (#1338)
waltaskew May 7, 2025
1d36f4d
test: add explicit credentials and project to test (#1372)
olavloite May 7, 2025
fd4ee67
build: exclude presubmit.cfg from owlbot generation (#1373)
olavloite May 7, 2025
3a91671
chore(x-goog-spanner-request-id): plug in functionality after test sc…
odeke-em May 17, 2025
1f4e98c
test: add a test for unary retries of UNAVAILABLE (#1376)
olavloite May 20, 2025
de322f8
docs: fix markdown formatting in transactions page (#1377)
rahul2393 May 20, 2025
bae395d
chore(x-goog-spanner-request-id): add x_goog_spanner_request_id as an…
odeke-em May 21, 2025
d532d57
chore: Update gapic-generator-python to 1.24.1 (#1314)
gcf-owl-bot[bot] May 21, 2025
b433281
chore(x-goog-spanner-request-id): more updates for batch_write + mock…
odeke-em May 22, 2025
aa4880b
chore: add samples for transaction timeout configuration (#1380)
alkatrivedi May 27, 2025
97d7268
feat: Add support for multiplexed sessions (#1381)
rahul2393 May 28, 2025
234135d
chore(main): release 3.55.0 (#1363)
release-please[bot] May 28, 2025
f9fd347
chore: add sample to set statement timeout within a transaciton (#1384)
alkatrivedi Jun 4, 2025
d35a0cc
Update `SessionOptions` to support `GOOGLE_CLOUD_SPANNER_FORCE_DISABL…
currantw May 29, 2025
34baadf
feat: Multiplexed sessions - Remove handling of `MethodNotImplemented…
currantw May 29, 2025
998f23f
feat: Multiplexed sessions - Update `Connection` to use multiplexed s…
currantw May 30, 2025
ec19f2d
cleanup: Rename `beforeNextRetry` to `before_next_retry`.
currantw May 30, 2025
25d0943
cleanup: Fix a few unrelated typos.
currantw May 30, 2025
fca6f06
feat: Multiplexed sessions - Add ingest of precommit tokens to `_Snap…
currantw May 30, 2025
56001b9
feat: Multiplexed sessions - Deprecate `StreamedResultSet._source` (r…
currantw May 30, 2025
b4eadca
feat: Multiplexed sessions - Move `_session_options` from `Database` …
currantw May 30, 2025
68e9b67
feat: Multiplexed sessions - Deprecate `SessionCheckout` and update `…
currantw May 30, 2025
6ca0d3f
feat: Multiplexed sessions - Deprecate `Database.session()` and minor…
currantw May 31, 2025
9057a64
feat: Multiplexed sessions - Update `BatchSnapshot` to use database s…
currantw May 31, 2025
c9dd818
feat: Multiplexed sessions - Move `Batch` and `Transaction` attribute…
currantw Jun 2, 2025
599939a
feat: Multiplexed sessions - Update pools so they don't use deprecate…
currantw Jun 2, 2025
2065e52
feat: Multiplexed sessions - Update session to remove class attribute…
currantw Jun 2, 2025
7b925b3
feat: Multiplexed sessions - Move begin transaction logic from `Snaps…
currantw Jun 3, 2025
9246dd2
feat: Multiplexed sessions - Remove begin transaction logic from `Tra…
currantw Jun 3, 2025
f1b3fdb
feat: Multiplexed sessions - Add logic for beginning mutations-only t…
currantw Jun 3, 2025
98c477d
feat: Multiplexed sessions - Cleanup and improve consistency of state…
currantw Jun 3, 2025
052f3e1
feat: Multiplexed sessions - Cleanup documentation for `Batch.commit`…
currantw Jun 3, 2025
2b9f212
feat: Multiplexed sessions - Add logic for retrying commits if precom…
currantw Jun 3, 2025
a77cc2b
feat: Multiplexed sessions - Remove `GOOGLE_CLOUD_SPANNER_FORCE_DISAB…
currantw Jun 4, 2025
5615f2c
feat: Multiplexed sessions - Cleanup `TestDatabaseSessionManager` so …
currantw Jun 4, 2025
00059f9
feat: Multiplexed sessions - Add type hints for `SessionOptions` and …
currantw Jun 4, 2025
083d6bc
feat: Multiplexed sessions - Fix `test_observability_options`
currantw Jun 4, 2025
6e33b1d
feat: Multiplexed sessions - Update `_builders` to use mock scoped cr…
currantw Jun 4, 2025
65042ab
feat: Multiplexed sessions - Add helpers for mock scoped credentials …
currantw Jun 4, 2025
9df088d
feat: Multiplexed sessions - Fix failing `test_batch_insert_then_read`.
currantw Jun 4, 2025
607df64
feat: Multiplexed sessions - Fix failing `test_transaction_read_and_i…
currantw Jun 4, 2025
0b6f5df
feat: Multiplexed sessions - Add test helper for multiplexed env vars.
currantw Jun 4, 2025
36c9775
feat: Multiplexed sessions - Add unit tests for begin transaction bas…
currantw Jun 4, 2025
418edda
feat: Multiplexed sessions - Attempt to fix `test_transaction_read_an…
currantw Jun 4, 2025
da226c1
feat: Multiplexed sessions - Add test for log when new session create…
currantw Jun 4, 2025
c6c130e
feat: Multiplexed sessions - Add additional multiplexed unit tests fo…
currantw Jun 4, 2025
1018f4c
feat: Multiplexed sessions - Cleanup `Transaction` by extracting some…
currantw Jun 4, 2025
b761e85
feat: Multiplexed sessions - Add additional `Transaction` tests for n…
currantw Jun 5, 2025
665547b
feat: Multiplexed sessions - Fix linter
currantw Jun 5, 2025
0bd5fd1
feat: Multiplexed sessions - Remove unnecessary TODO
currantw Jun 5, 2025
4cb1f05
feat: Multiplexed sessions - Remove unnecessary constants.
currantw Jun 5, 2025
17f3c5f
feat: Multiplexed sessions - Remove support for disabling the use of …
currantw Jun 5, 2025
9c3db74
feat: Multiplexed sessions - Make deprecation comments a bit more clear.
currantw Jun 9, 2025
17a2f47
feat: Multiplexed sessions - Add some more type hints.
currantw Jun 9, 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
Prev Previous commit
Next Next commit
fix: pass through kwargs in dbapi connect (googleapis#1368)
* fix: pass through kwargs in dbapi connect

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
olavloite and gcf-owl-bot[bot] authored May 6, 2025
commit aae8d6161580c88354d813fe75a297c318f1c2c7
2 changes: 1 addition & 1 deletion google/cloud/spanner_dbapi/connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -798,7 +798,7 @@ def connect(
database = None
if database_id:
database = instance.database(database_id, pool=pool)
conn = Connection(instance, database)
conn = Connection(instance, database, **kwargs)
if pool is not None:
conn._own_pool = False

Expand Down
14 changes: 14 additions & 0 deletions tests/unit/spanner_dbapi/test_connect.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,3 +131,17 @@ def test_w_credential_file_path(self, mock_client):
client_info = factory.call_args_list[0][1]["client_info"]
self.assertEqual(client_info.user_agent, USER_AGENT)
self.assertEqual(client_info.python_version, PY_VERSION)

def test_with_kwargs(self, mock_client):
from google.cloud.spanner_dbapi import connect
from google.cloud.spanner_dbapi import Connection

client = mock_client.return_value
instance = client.instance.return_value
database = instance.database.return_value
self.assertIsNotNone(database)

connection = connect(INSTANCE, DATABASE, ignore_transaction_warnings=True)

self.assertIsInstance(connection, Connection)
self.assertTrue(connection._ignore_transaction_warnings)