Skip to content

Commit 911f8a5

Browse files
committed
fixed lint errors
1 parent 2091f00 commit 911f8a5

File tree

2 files changed

+3
-12
lines changed

2 files changed

+3
-12
lines changed

pyiceberg/cli/console.py

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -199,12 +199,6 @@ def delete_files(
199199
branch: str | None,
200200
properties: tuple[str, ...],
201201
) -> None:
202-
203-
204-
"""
205-
Remove one or more data files from the table by path
206-
"""
207-
208202
"""Remove one or more data files from the table by path."""
209203
if not file_paths:
210204
raise click.UsageError("At least one file path is required.")
@@ -224,11 +218,7 @@ def delete_files(
224218
for item in file_paths:
225219
file_paths_list.append(item)
226220

227-
table.delete_files(
228-
file_paths=list(file_paths),
229-
branch=branch or MAIN_BRANCH,
230-
snapshot_properties=snapshot_properties
231-
)
221+
table.delete_files(file_paths=list(file_paths), branch=branch or MAIN_BRANCH, snapshot_properties=snapshot_properties)
232222
output.text(f"Deleted {len(file_paths)} file(s) from {identifier}")
233223

234224

@@ -526,4 +516,4 @@ def _retention_properties(ref: SnapshotRef, table_properties: dict[str, str]) ->
526516

527517

528518
if __name__ == "__main__":
529-
run()
519+
run()

tests/cli/test_console.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1030,6 +1030,7 @@ def test_log_level_cli_overrides_env(mocker: MockFixture) -> None:
10301030
call_kwargs = mock_basicConfig.call_args[1]
10311031
assert call_kwargs["level"] == logging.ERROR
10321032

1033+
10331034
def test_delete_files_requires_at_least_one_path(catalog: InMemoryCatalog) -> None:
10341035
runner = CliRunner()
10351036
result = runner.invoke(run, ["delete-files", "default.my_table"])

0 commit comments

Comments
 (0)