File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -423,7 +423,7 @@ def ancestor_right_before_timestamp(
423423 current_snapshot : Optional [Snapshot ], table_metadata : TableMetadata , timestamp_ms : int
424424) -> Optional [Snapshot ]:
425425 """Get the ancestor right before the given timestamp."""
426- if current_snapshot is not None :
426+ if current_snapshot :
427427 for ancestor in ancestors_of (current_snapshot , table_metadata ):
428428 if ancestor .timestamp_ms < timestamp_ms :
429429 return ancestor
Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ def test_manage_snapshots_context_manager(catalog: Catalog) -> None:
5353 with tbl .manage_snapshots () as ms :
5454 ms .create_tag (snapshot_id = current_snapshot_id , tag_name = "testing" )
5555 ms .set_current_snapshot (snapshot_id = expected_snapshot_id )
56- ms .create_tag (snapshot_id = expected_snapshot_id , tag_name = "testing2" )
56+ ms .create_branch (snapshot_id = expected_snapshot_id , branch_name = "testing2" )
5757 assert tbl .current_snapshot ().snapshot_id is not current_snapshot_id # type: ignore
5858 assert tbl .metadata .refs ["testing" ].snapshot_id == current_snapshot_id
5959 assert tbl .metadata .refs ["main" ] == SnapshotRef (snapshot_id = expected_snapshot_id , snapshot_ref_type = "branch" )
You can’t perform that action at this time.
0 commit comments