See http://googlecloudplatform.github.io/gcloud-python/latest/datastore-transactions.html#gcloud.datastore.transaction.Transaction
Snippet is
>>>fromgcloudimportdatastore>>>fromgcloud.datastore.transactionimportTransaction>>>datastore.set_defaults()
>>>withTransaction():
... datastore.put([entity1, entity2])
I'd expect it to be
>>>fromgcloudimportdatastore>>>withdatastore.Transaction():
... datastore.put([entity1, entity2])
See http://googlecloudplatform.github.io/gcloud-python/latest/datastore-transactions.html#gcloud.datastore.transaction.Transaction
Snippet is
I'd expect it to be