File tree Expand file tree Collapse file tree 2 files changed +3
-5
lines changed Expand file tree Collapse file tree 2 files changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -149,7 +149,7 @@ async def check_transaction(s: ydb.aio.table.Session):
149149 with pytest .raises (RuntimeError ):
150150 await tx .execute ("INSERT INTO %s (id) VALUES (2)" % table_name )
151151
152- tx .commit ()
152+ await tx .commit ()
153153
154154 async with s .transaction () as tx :
155155 rs = await tx .execute ("SELECT COUNT(*) as cnt FROM %s" % table_name )
Original file line number Diff line number Diff line change @@ -2454,8 +2454,7 @@ def async_commit(self, settings=None):
24542454
24552455 :return: A future of commit call
24562456 """
2457- self ._check_split ()
2458- self ._finished = True
2457+ self ._set_finish (self ._COMMIT )
24592458
24602459 if self ._tx_state .tx_id is None and not self ._tx_state .dead :
24612460 return _utilities .wrap_result_in_future (self )
@@ -2480,8 +2479,7 @@ def async_rollback(self, settings=None):
24802479
24812480 :return: A future of rollback call
24822481 """
2483- self ._check_split ()
2484- self ._finished = True
2482+ self ._set_finish (self ._ROLLBACK )
24852483
24862484 if self ._tx_state .tx_id is None and not self ._tx_state .dead :
24872485 return _utilities .wrap_result_in_future (self )
You can’t perform that action at this time.
0 commit comments