Skip to content

Commit 6f14a98

Browse files
committed
Do not auto-install in dry-run mode
1 parent c3b7b06 commit 6f14a98

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/cloudai/cli/handlers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -268,15 +268,15 @@ def handle_dry_run_and_run(args: argparse.Namespace) -> int:
268268
logging.info(f"Test Scenario Name: {test_scenario.name}")
269269

270270
result = _check_installation(args, system, tests, test_scenario)
271-
if not result.success:
271+
if args.mode == "run" and not result.success:
272272
logging.info("Not all workloads components are installed. Installing...")
273273
installables, installer = prepare_installation(system, tests, test_scenario)
274274

275275
result = installer.install(installables)
276276
if result.success:
277277
logging.info(f"CloudAI is successfully installed into '{system.install_path.absolute()}'.")
278278
else:
279-
logging.error("Failed to install workloads' components.")
279+
logging.error("Failed to install workloads components.")
280280
logging.error(result.message)
281281
return 1
282282

0 commit comments

Comments
 (0)