google-cloud-spanner 3.61.0__tar.gz → 3.62.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {google_cloud_spanner-3.61.0/google_cloud_spanner.egg-info → google_cloud_spanner-3.62.0}/PKG-INFO +1 -1
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/gapic_version.py +1 -1
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/gapic_version.py +1 -1
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/parse_utils.py +5 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/version.py +1 -1
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/_helpers.py +9 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/gapic_version.py +1 -1
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/param_types.py +1 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/snapshot.py +31 -46
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/streamed.py +1 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/transaction.py +3 -1
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0/google_cloud_spanner.egg-info}/PKG-INFO +1 -1
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_session_api.py +13 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_parse_utils.py +23 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test__helpers.py +13 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_session.py +4 -1
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_snapshot.py +50 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_transaction.py +1 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/LICENSE +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/MANIFEST.in +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/README.rst +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/gapic_metadata.json +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/py.typed +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/async_client.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/client.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/pagers.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/transports/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/transports/base.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/transports/grpc.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/transports/grpc_asyncio.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/transports/rest.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/services/database_admin/transports/rest_base.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/types/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/types/backup.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/types/backup_schedule.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/types/common.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_database_v1/types/spanner_database_admin.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/gapic_metadata.json +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/py.typed +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/async_client.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/client.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/pagers.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/transports/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/transports/base.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/transports/grpc.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/transports/grpc_asyncio.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/transports/rest.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/services/instance_admin/transports/rest_base.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/types/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/types/common.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_admin_instance_v1/types/spanner_instance_admin.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/_helpers.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/batch_dml_executor.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/checksum.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/client_side_statement_executor.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/client_side_statement_parser.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/connection.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/cursor.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/exceptions.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/parsed_statement.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/parser.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/partition_helper.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/transaction_helper.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/types.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/utils.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/_opentelemetry_tracing.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/backup.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/batch.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/client.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/data_types.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/database.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/database_sessions_manager.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/gapic_metadata.json +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/instance.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/keyset.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/merged_result_set.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/metrics/constants.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/metrics/metrics_capture.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/metrics/metrics_exporter.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/metrics/metrics_interceptor.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/metrics/metrics_tracer.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/metrics/metrics_tracer_factory.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/metrics/spanner_metrics_tracer_factory.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/pool.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/py.typed +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/request_id_header.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/async_client.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/client.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/pagers.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/transports/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/transports/base.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/transports/grpc.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/transports/grpc_asyncio.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/transports/rest.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/services/spanner/transports/rest_base.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/session.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/table.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/testing/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/testing/database_test.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/testing/interceptors.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/testing/mock_database_admin.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/testing/mock_spanner.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/testing/spanner_database_admin_pb2_grpc.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/testing/spanner_pb2_grpc.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/change_stream.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/commit_response.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/keys.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/location.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/mutation.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/query_plan.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/result_set.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/spanner.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/transaction.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/types/type.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google_cloud_spanner.egg-info/SOURCES.txt +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google_cloud_spanner.egg-info/dependency_links.txt +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google_cloud_spanner.egg-info/not-zip-safe +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google_cloud_spanner.egg-info/requires.txt +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google_cloud_spanner.egg-info/top_level.txt +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/setup.cfg +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/setup.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/_builders.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/_fixtures.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/_helpers.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/mockserver_tests/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/mockserver_tests/mock_server_test_base.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/mockserver_tests/test_aborted_transaction.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/mockserver_tests/test_basics.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/mockserver_tests/test_dbapi_autocommit.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/mockserver_tests/test_dbapi_isolation_level.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/mockserver_tests/test_request_id_header.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/mockserver_tests/test_tags.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/_helpers.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/_sample_data.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/conftest.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_backup_api.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_database_api.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_dbapi.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_instance_api.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_metrics.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_observability_options.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_streaming_chunking.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_table_api.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/testdata/descriptors.pb +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/testdata/singer.proto +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/testdata/singer_pb2.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/utils/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/utils/clear_streaming.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/utils/populate_streaming.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/utils/scrub_instances.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/utils/streaming_utils.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/gapic/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/gapic/spanner_admin_database_v1/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/gapic/spanner_admin_database_v1/test_database_admin.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/gapic/spanner_admin_instance_v1/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/gapic/spanner_admin_instance_v1/test_instance_admin.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/gapic/spanner_v1/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/gapic/spanner_v1/test_spanner.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/__init__.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test__helpers.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_batch_dml_executor.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_checksum.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_client_side_statement_executor.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_connect.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_connection.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_cursor.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_globals.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_parser.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_transaction_helper.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_types.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/spanner_dbapi/test_utils.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/streaming-read-acceptance-test.json +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test__opentelemetry_tracing.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_atomic_counter.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_backup.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_batch.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_client.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_database.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_database_session_manager.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_datatypes.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_instance.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_keyset.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_merged_result_set.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_metrics.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_metrics_capture.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_metrics_exporter.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_metrics_interceptor.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_metrics_tracer.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_metrics_tracer_factory.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_packaging.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_param_types.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_pool.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_spanner.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_spanner_metrics_tracer_factory.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_streamed.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/test_table.py +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/testdata/singer.proto +0 -0
- {google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/unit/testdata/singer_pb2.py +0 -0
|
@@ -233,6 +233,11 @@ def classify_statement(query, args=None):
|
|
|
233
233
|
:rtype: ParsedStatement
|
|
234
234
|
:returns: parsed statement attributes.
|
|
235
235
|
"""
|
|
236
|
+
# Check for RUN PARTITION command to avoid sqlparse processing it.
|
|
237
|
+
# sqlparse fails with "Maximum grouping depth exceeded" on long partition IDs.
|
|
238
|
+
if re.match(r"^\s*RUN\s+PARTITION\s+.+", query, re.IGNORECASE):
|
|
239
|
+
return client_side_statement_parser.parse_stmt(query.strip())
|
|
240
|
+
|
|
236
241
|
# sqlparse will strip Cloud Spanner comments,
|
|
237
242
|
# still, special commenting styles, like
|
|
238
243
|
# PostgreSQL dollar quoted comments are not
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/_helpers.py
RENAMED
|
@@ -21,6 +21,7 @@ import time
|
|
|
21
21
|
import base64
|
|
22
22
|
import threading
|
|
23
23
|
import logging
|
|
24
|
+
import uuid
|
|
24
25
|
|
|
25
26
|
from google.protobuf.struct_pb2 import ListValue
|
|
26
27
|
from google.protobuf.struct_pb2 import Value
|
|
@@ -298,6 +299,8 @@ def _make_value_pb(value):
|
|
|
298
299
|
return Value(string_value=base64.b64encode(value))
|
|
299
300
|
if isinstance(value, Interval):
|
|
300
301
|
return Value(string_value=str(value))
|
|
302
|
+
if isinstance(value, uuid.UUID):
|
|
303
|
+
return Value(string_value=str(value))
|
|
301
304
|
|
|
302
305
|
raise ValueError("Unknown type: %s" % (value,))
|
|
303
306
|
|
|
@@ -399,6 +402,8 @@ def _get_type_decoder(field_type, field_name, column_info=None):
|
|
|
399
402
|
return _parse_numeric
|
|
400
403
|
elif type_code == TypeCode.JSON:
|
|
401
404
|
return _parse_json
|
|
405
|
+
elif type_code == TypeCode.UUID:
|
|
406
|
+
return _parse_uuid
|
|
402
407
|
elif type_code == TypeCode.PROTO:
|
|
403
408
|
return lambda value_pb: _parse_proto(value_pb, column_info, field_name)
|
|
404
409
|
elif type_code == TypeCode.ENUM:
|
|
@@ -481,6 +486,10 @@ def _parse_json(value_pb):
|
|
|
481
486
|
return JsonObject.from_str(value_pb.string_value)
|
|
482
487
|
|
|
483
488
|
|
|
489
|
+
def _parse_uuid(value_pb):
|
|
490
|
+
return uuid.UUID(value_pb.string_value)
|
|
491
|
+
|
|
492
|
+
|
|
484
493
|
def _parse_proto(value_pb, column_info, field_name):
|
|
485
494
|
bytes_value = base64.b64decode(value_pb.string_value)
|
|
486
495
|
if column_info is not None and column_info.get(field_name) is not None:
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/param_types.py
RENAMED
|
@@ -33,6 +33,7 @@ DATE = Type(code=TypeCode.DATE)
|
|
|
33
33
|
TIMESTAMP = Type(code=TypeCode.TIMESTAMP)
|
|
34
34
|
NUMERIC = Type(code=TypeCode.NUMERIC)
|
|
35
35
|
JSON = Type(code=TypeCode.JSON)
|
|
36
|
+
UUID = Type(code=TypeCode.UUID)
|
|
36
37
|
PG_NUMERIC = Type(code=TypeCode.NUMERIC, type_annotation=TypeAnnotationCode.PG_NUMERIC)
|
|
37
38
|
PG_JSONB = Type(code=TypeCode.JSON, type_annotation=TypeAnnotationCode.PG_JSONB)
|
|
38
39
|
PG_OID = Type(code=TypeCode.INT64, type_annotation=TypeAnnotationCode.PG_OID)
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/snapshot.py
RENAMED
|
@@ -146,27 +146,12 @@ def _restart_on_unavailable(
|
|
|
146
146
|
|
|
147
147
|
except ServiceUnavailable:
|
|
148
148
|
del item_buffer[:]
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
) as span, MetricsCapture():
|
|
156
|
-
request.resume_token = resume_token
|
|
157
|
-
if transaction is not None:
|
|
158
|
-
transaction_selector = transaction._build_transaction_selector_pb()
|
|
159
|
-
request.transaction = transaction_selector
|
|
160
|
-
attempt += 1
|
|
161
|
-
iterator = method(
|
|
162
|
-
request=request,
|
|
163
|
-
metadata=request_id_manager.metadata_with_request_id(
|
|
164
|
-
nth_request,
|
|
165
|
-
attempt,
|
|
166
|
-
metadata,
|
|
167
|
-
span,
|
|
168
|
-
),
|
|
169
|
-
)
|
|
149
|
+
request.resume_token = resume_token
|
|
150
|
+
if transaction is not None:
|
|
151
|
+
transaction_selector = transaction._build_transaction_selector_pb()
|
|
152
|
+
request.transaction = transaction_selector
|
|
153
|
+
attempt += 1
|
|
154
|
+
iterator = None
|
|
170
155
|
continue
|
|
171
156
|
|
|
172
157
|
except InternalServerError as exc:
|
|
@@ -177,27 +162,12 @@ def _restart_on_unavailable(
|
|
|
177
162
|
if not resumable_error:
|
|
178
163
|
raise
|
|
179
164
|
del item_buffer[:]
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
) as span, MetricsCapture():
|
|
187
|
-
request.resume_token = resume_token
|
|
188
|
-
if transaction is not None:
|
|
189
|
-
transaction_selector = transaction._build_transaction_selector_pb()
|
|
190
|
-
attempt += 1
|
|
191
|
-
request.transaction = transaction_selector
|
|
192
|
-
iterator = method(
|
|
193
|
-
request=request,
|
|
194
|
-
metadata=request_id_manager.metadata_with_request_id(
|
|
195
|
-
nth_request,
|
|
196
|
-
attempt,
|
|
197
|
-
metadata,
|
|
198
|
-
span,
|
|
199
|
-
),
|
|
200
|
-
)
|
|
165
|
+
request.resume_token = resume_token
|
|
166
|
+
if transaction is not None:
|
|
167
|
+
transaction_selector = transaction._build_transaction_selector_pb()
|
|
168
|
+
attempt += 1
|
|
169
|
+
request.transaction = transaction_selector
|
|
170
|
+
iterator = None
|
|
201
171
|
continue
|
|
202
172
|
|
|
203
173
|
if len(item_buffer) == 0:
|
|
@@ -901,13 +871,19 @@ class _SnapshotBase(_SessionWrapper):
|
|
|
901
871
|
|
|
902
872
|
return [partition.partition_token for partition in response.partitions]
|
|
903
873
|
|
|
904
|
-
def _begin_transaction(
|
|
874
|
+
def _begin_transaction(
|
|
875
|
+
self, mutation: Mutation = None, transaction_tag: str = None
|
|
876
|
+
) -> bytes:
|
|
905
877
|
"""Begins a transaction on the database.
|
|
906
878
|
|
|
907
879
|
:type mutation: :class:`~google.cloud.spanner_v1.mutation.Mutation`
|
|
908
880
|
:param mutation: (Optional) Mutation to include in the begin transaction
|
|
909
881
|
request. Required for mutation-only transactions with multiplexed sessions.
|
|
910
882
|
|
|
883
|
+
:type transaction_tag: str
|
|
884
|
+
:param transaction_tag: (Optional) Transaction tag to include in the begin transaction
|
|
885
|
+
request.
|
|
886
|
+
|
|
911
887
|
:rtype: bytes
|
|
912
888
|
:returns: identifier for the transaction.
|
|
913
889
|
|
|
@@ -931,6 +907,17 @@ class _SnapshotBase(_SessionWrapper):
|
|
|
931
907
|
(_metadata_with_leader_aware_routing(database._route_to_leader_enabled))
|
|
932
908
|
)
|
|
933
909
|
|
|
910
|
+
begin_request_kwargs = {
|
|
911
|
+
"session": session.name,
|
|
912
|
+
"options": self._build_transaction_selector_pb().begin,
|
|
913
|
+
"mutation_key": mutation,
|
|
914
|
+
}
|
|
915
|
+
|
|
916
|
+
if transaction_tag:
|
|
917
|
+
begin_request_kwargs["request_options"] = RequestOptions(
|
|
918
|
+
transaction_tag=transaction_tag
|
|
919
|
+
)
|
|
920
|
+
|
|
934
921
|
with trace_call(
|
|
935
922
|
name=f"CloudSpanner.{type(self).__name__}.begin",
|
|
936
923
|
session=session,
|
|
@@ -942,9 +929,7 @@ class _SnapshotBase(_SessionWrapper):
|
|
|
942
929
|
|
|
943
930
|
def wrapped_method():
|
|
944
931
|
begin_transaction_request = BeginTransactionRequest(
|
|
945
|
-
|
|
946
|
-
options=self._build_transaction_selector_pb().begin,
|
|
947
|
-
mutation_key=mutation,
|
|
932
|
+
**begin_request_kwargs
|
|
948
933
|
)
|
|
949
934
|
begin_transaction_method = functools.partial(
|
|
950
935
|
api.begin_transaction,
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/transaction.py
RENAMED
|
@@ -714,7 +714,9 @@ class Transaction(_SnapshotBase, _BatchBase):
|
|
|
714
714
|
if self.rolled_back:
|
|
715
715
|
raise ValueError("Transaction is already rolled back")
|
|
716
716
|
|
|
717
|
-
return super(Transaction, self)._begin_transaction(
|
|
717
|
+
return super(Transaction, self)._begin_transaction(
|
|
718
|
+
mutation=mutation, transaction_tag=self.transaction_tag
|
|
719
|
+
)
|
|
718
720
|
|
|
719
721
|
def _begin_mutations_only_transaction(self) -> None:
|
|
720
722
|
"""Begins a mutations-only transaction on the database."""
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/tests/system/test_session_api.py
RENAMED
|
@@ -20,6 +20,7 @@ import math
|
|
|
20
20
|
import struct
|
|
21
21
|
import threading
|
|
22
22
|
import time
|
|
23
|
+
import uuid
|
|
23
24
|
import pytest
|
|
24
25
|
|
|
25
26
|
import grpc
|
|
@@ -3056,6 +3057,18 @@ def test_execute_sql_returning_transfinite_floats(sessions_database, not_postgre
|
|
|
3056
3057
|
assert math.isnan(float_array[2])
|
|
3057
3058
|
|
|
3058
3059
|
|
|
3060
|
+
def test_execute_sql_w_uuid_bindings(sessions_database, database_dialect):
|
|
3061
|
+
if database_dialect == DatabaseDialect.POSTGRESQL:
|
|
3062
|
+
pytest.skip("UUID parameter type is not yet supported in PostgreSQL dialect.")
|
|
3063
|
+
_bind_test_helper(
|
|
3064
|
+
sessions_database,
|
|
3065
|
+
database_dialect,
|
|
3066
|
+
spanner_v1.param_types.UUID,
|
|
3067
|
+
uuid.uuid4(),
|
|
3068
|
+
[uuid.uuid4(), uuid.uuid4()],
|
|
3069
|
+
)
|
|
3070
|
+
|
|
3071
|
+
|
|
3059
3072
|
def test_partition_query(sessions_database, not_emulator, not_experimental_host):
|
|
3060
3073
|
row_count = 40
|
|
3061
3074
|
sql = f"SELECT * FROM {_sample_data.TABLE}"
|
|
@@ -200,6 +200,29 @@ class TestParseUtils(unittest.TestCase):
|
|
|
200
200
|
),
|
|
201
201
|
)
|
|
202
202
|
|
|
203
|
+
def test_run_partition_classify_stmt_long_id(self):
|
|
204
|
+
# Regression test for "Maximum grouping depth exceeded" with sqlparse
|
|
205
|
+
long_id = "a" * 5000
|
|
206
|
+
query = f"RUN PARTITION {long_id}"
|
|
207
|
+
parsed_statement = classify_statement(query)
|
|
208
|
+
self.assertEqual(
|
|
209
|
+
parsed_statement,
|
|
210
|
+
ParsedStatement(
|
|
211
|
+
StatementType.CLIENT_SIDE,
|
|
212
|
+
Statement(query),
|
|
213
|
+
ClientSideStatementType.RUN_PARTITION,
|
|
214
|
+
[long_id],
|
|
215
|
+
),
|
|
216
|
+
)
|
|
217
|
+
|
|
218
|
+
def test_run_partition_classify_stmt_incomplete(self):
|
|
219
|
+
# "RUN PARTITION" without ID should be classified as UNKNOWN (not None)
|
|
220
|
+
# because it falls through the specific check and sqlparse handles it.
|
|
221
|
+
query = "RUN PARTITION"
|
|
222
|
+
parsed_statement = classify_statement(query)
|
|
223
|
+
self.assertEqual(parsed_statement.statement_type, StatementType.UNKNOWN)
|
|
224
|
+
self.assertEqual(parsed_statement.statement.sql, query)
|
|
225
|
+
|
|
203
226
|
def test_run_partitioned_query_classify_stmt(self):
|
|
204
227
|
parsed_statement = classify_statement(
|
|
205
228
|
" RUN PARTITIONED QUERY SELECT s.SongName FROM Songs AS s "
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
import unittest
|
|
17
|
+
import uuid
|
|
17
18
|
import mock
|
|
18
19
|
|
|
19
20
|
from opentelemetry.sdk.resources import Resource
|
|
@@ -786,6 +787,18 @@ class Test_parse_value_pb(unittest.TestCase):
|
|
|
786
787
|
self._callFUT(value_pb, field_type, field_name, column_info), VALUE
|
|
787
788
|
)
|
|
788
789
|
|
|
790
|
+
def test_w_uuid(self):
|
|
791
|
+
from google.protobuf.struct_pb2 import Value
|
|
792
|
+
from google.cloud.spanner_v1 import Type
|
|
793
|
+
from google.cloud.spanner_v1 import TypeCode
|
|
794
|
+
|
|
795
|
+
VALUE = uuid.uuid4()
|
|
796
|
+
field_type = Type(code=TypeCode.UUID)
|
|
797
|
+
field_name = "uuid_column"
|
|
798
|
+
value_pb = Value(string_value=str(VALUE))
|
|
799
|
+
|
|
800
|
+
self.assertEqual(self._callFUT(value_pb, field_type, field_name), VALUE)
|
|
801
|
+
|
|
789
802
|
|
|
790
803
|
class Test_parse_list_value_pbs(unittest.TestCase):
|
|
791
804
|
def _callFUT(self, *args, **kw):
|
|
@@ -2005,9 +2005,12 @@ class TestSession(OpenTelemetryBase):
|
|
|
2005
2005
|
self.assertEqual(kw, {"some_arg": "def"})
|
|
2006
2006
|
|
|
2007
2007
|
expected_options = TransactionOptions(read_write=TransactionOptions.ReadWrite())
|
|
2008
|
+
expected_request_options = RequestOptions(transaction_tag=transaction_tag)
|
|
2008
2009
|
gax_api.begin_transaction.assert_called_once_with(
|
|
2009
2010
|
request=BeginTransactionRequest(
|
|
2010
|
-
session=self.SESSION_NAME,
|
|
2011
|
+
session=self.SESSION_NAME,
|
|
2012
|
+
options=expected_options,
|
|
2013
|
+
request_options=expected_request_options,
|
|
2011
2014
|
),
|
|
2012
2015
|
metadata=[
|
|
2013
2016
|
("google-cloud-resource-prefix", database.name),
|
|
@@ -405,6 +405,56 @@ class Test_restart_on_unavailable(OpenTelemetryBase):
|
|
|
405
405
|
self.assertEqual(request.resume_token, RESUME_TOKEN)
|
|
406
406
|
self.assertNoSpans()
|
|
407
407
|
|
|
408
|
+
def test_iteration_w_raw_raising_unavailable_during_restart(self):
|
|
409
|
+
from google.api_core.exceptions import ServiceUnavailable
|
|
410
|
+
|
|
411
|
+
FIRST = (self._make_item(0), self._make_item(1, resume_token=RESUME_TOKEN))
|
|
412
|
+
LAST = (self._make_item(2),)
|
|
413
|
+
before = _MockIterator(
|
|
414
|
+
*FIRST, fail_after=True, error=ServiceUnavailable("testing")
|
|
415
|
+
)
|
|
416
|
+
after = _MockIterator(*LAST)
|
|
417
|
+
request = mock.Mock(test="test", spec=["test", "resume_token"])
|
|
418
|
+
# The second call (the first retry) raises ServiceUnavailable immediately.
|
|
419
|
+
# The third call (the second retry) succeeds.
|
|
420
|
+
restart = mock.Mock(
|
|
421
|
+
spec=[],
|
|
422
|
+
side_effect=[before, ServiceUnavailable("retry failed"), after],
|
|
423
|
+
)
|
|
424
|
+
database = _Database()
|
|
425
|
+
database.spanner_api = build_spanner_api()
|
|
426
|
+
session = _Session(database)
|
|
427
|
+
derived = _build_snapshot_derived(session)
|
|
428
|
+
resumable = self._call_fut(derived, restart, request, session=session)
|
|
429
|
+
self.assertEqual(list(resumable), list(FIRST + LAST))
|
|
430
|
+
self.assertEqual(len(restart.mock_calls), 3)
|
|
431
|
+
self.assertEqual(request.resume_token, RESUME_TOKEN)
|
|
432
|
+
self.assertNoSpans()
|
|
433
|
+
|
|
434
|
+
def test_iteration_w_raw_raising_resumable_internal_error_during_restart(self):
|
|
435
|
+
FIRST = (self._make_item(0), self._make_item(1, resume_token=RESUME_TOKEN))
|
|
436
|
+
LAST = (self._make_item(2),)
|
|
437
|
+
before = _MockIterator(
|
|
438
|
+
*FIRST,
|
|
439
|
+
fail_after=True,
|
|
440
|
+
error=INTERNAL_SERVER_ERROR_UNEXPECTED_EOS,
|
|
441
|
+
)
|
|
442
|
+
after = _MockIterator(*LAST)
|
|
443
|
+
request = mock.Mock(test="test", spec=["test", "resume_token"])
|
|
444
|
+
restart = mock.Mock(
|
|
445
|
+
spec=[],
|
|
446
|
+
side_effect=[before, INTERNAL_SERVER_ERROR_UNEXPECTED_EOS, after],
|
|
447
|
+
)
|
|
448
|
+
database = _Database()
|
|
449
|
+
database.spanner_api = build_spanner_api()
|
|
450
|
+
session = _Session(database)
|
|
451
|
+
derived = _build_snapshot_derived(session)
|
|
452
|
+
resumable = self._call_fut(derived, restart, request, session=session)
|
|
453
|
+
self.assertEqual(list(resumable), list(FIRST + LAST))
|
|
454
|
+
self.assertEqual(len(restart.mock_calls), 3)
|
|
455
|
+
self.assertEqual(request.resume_token, RESUME_TOKEN)
|
|
456
|
+
self.assertNoSpans()
|
|
457
|
+
|
|
408
458
|
def test_iteration_w_raw_w_multiuse(self):
|
|
409
459
|
from google.cloud.spanner_v1 import (
|
|
410
460
|
ReadRequest,
|
|
@@ -467,6 +467,7 @@ class TestTransaction(OpenTelemetryBase):
|
|
|
467
467
|
session=session.name,
|
|
468
468
|
options=TransactionOptions(read_write=TransactionOptions.ReadWrite()),
|
|
469
469
|
mutation_key=expected_begin_mutation,
|
|
470
|
+
request_options=RequestOptions(transaction_tag=TRANSACTION_TAG),
|
|
470
471
|
)
|
|
471
472
|
|
|
472
473
|
expected_begin_metadata = base_metadata.copy()
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/__init__.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/_helpers.py
RENAMED
|
File without changes
|
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/checksum.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/connection.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/cursor.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/exceptions.py
RENAMED
|
File without changes
|
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/parser.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/types.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_dbapi/utils.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/backup.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/batch.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/client.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/data_types.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/database.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/instance.py
RENAMED
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/keyset.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{google_cloud_spanner-3.61.0 → google_cloud_spanner-3.62.0}/google/cloud/spanner_v1/py.typed
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|