Fix snapshot api and test

This commit is contained in:
WQY\qiong
2023-02-24 13:46:19 +08:00
parent e88478fc13
commit c3ae9b306f
2 changed files with 16 additions and 8 deletions

View File

@@ -180,12 +180,12 @@ def take_snapshot_for_operation(name: str, operation: int, tag: str) -> None:
write(name, f"insert into snapshot_operation (id, tag) values ({operation}, '{tag}')")
def take_snapshot_for_current_operation(name: str, tag: str) -> int | None:
def take_snapshot_for_current_operation(name: str, tag: str) -> None:
take_snapshot_for_operation(name, get_current_operation(name), tag)
# deprecated ! use take_snapshot_for_current_operation instead
def take_snapshot(name: str, tag: str) -> int | None:
def take_snapshot(name: str, tag: str) -> None:
take_snapshot_for_current_operation(name, tag)