Skip to content

Spanner: database.transaction() does not work anymore #6029

@wawrencelu

Description

@wawrencelu

Hi, the docs state that I can start a transaction like so: https://googlecloudplatform.github.io/google-cloud-python/latest/spanner/transaction-usage.html#use-a-transaction-as-a-context-manager

with database.transaction() as transaction:

However, when I call it I receive an error saying that transaction attribute does not exist on the database object. Looking at the source, it looks like that method no longer exists either.

Why was it removed? Can we re-add it? Happy to submit a patch to do so.

Metadata

Metadata

Assignees

Labels

api: spannerIssues related to the Spanner API.type: docsImprovement to the documentation for an API.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions