Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Junhao Liao <junhao@junhao.ca>
  • Loading branch information
haiqi96 and junhaoliao authored Jul 11, 2024
1 parent e2aa05f commit e403604
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -165,13 +165,13 @@ def handle_extraction(parsed_args, clp_home: pathlib.Path, default_config_file_p
# fmt: on
if parsed_args.orig_file_id:
extract_cmd.append("--orig-file-id")
extract_cmd.append(str(parsed_args.target_size))
extract_cmd.append(str(parsed_args.orig_file_id))
else:
extract_cmd.append("--path")
extract_cmd.append(str(parsed_args.path))
if parsed_args.target_uncompressed_size:
extract_cmd.append("--target-uncompressed-size")
extract_cmd.append(str(parsed_args.target_size))
extract_cmd.append(str(parsed_args.target_uncompressed_size))
cmd = container_start_cmd + extract_cmd
subprocess.run(cmd, check=True)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def submit_and_monitor_ir_extraction_job_in_db(
db_config: Database,
orig_file_id: str,
msg_ix: int,
target_uncompressed_size: int | None,
target_uncompressed_size: Optional[int],
) -> None:
"""
Submits an IR extraction job to the scheduler database and
Expand Down Expand Up @@ -106,7 +106,7 @@ async def do_extract(
db_config: Database,
orig_file_id: str,
msg_ix: int,
target_uncompressed_size: int | None,
target_uncompressed_size: Optional[int],
):
await run_function_in_process(
submit_and_monitor_ir_extraction_job_in_db,
Expand Down

0 comments on commit e403604

Please sign in to comment.