From b28f8bb64de8c38f044b31cba7db4c32f5221c6d Mon Sep 17 00:00:00 2001 From: Wenqi Li Date: Fri, 5 Jun 2026 09:06:43 +0100 Subject: [PATCH 1/3] fix: align removed-command and HAP/MAP messaging with holoscan version convention holoscan-cli now versions in lockstep with the Holoscan SDK, so the internal "v1" codename is meaningless to users. Replace it with the public release version (holoscan v4.3.0) everywhere it appears in user-facing messaging: - src/holoscan_cli/__main__.py: removed-command error + footer strings and the explanatory comments - README.md: HOLOHUB_* env-var deprecation note and the HAP/MAP packaging deprecation section - tests/unit/test_main.py: pin the new "since holoscan v4.3.0" wording Supersedes the split work in #184 and #185. Co-Authored-By: Claude Opus 4.8 (1M context) --- README.md | 4 ++-- src/holoscan_cli/__main__.py | 12 ++++++------ tests/unit/test_main.py | 4 ++-- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index b2194af..c8b31d2 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ Per-repo wrappers install this package and delegate to `holoscan`, layering on t | [HoloHub](https://github.com/nvidia-holoscan/holohub) | `./holohub` | source-project metadata search paths, container/workspace names | | [I4H Workflows](https://github.com/isaac-for-healthcare/i4h-workflows) | `./i4h` | RTI DDS license auto-download + mount, TTY serial device passthrough | -Common env vars: `HOLOSCAN_CLI_ROOT` (repo root), `HOLOSCAN_CLI_SEARCH_PATH` (subdirs to scan for `metadata.json`), `HOLOSCAN_CLI_PATH_PREFIX` (placeholder prefix in metadata templates), `HOLOSCAN_CLI_REPO_PREFIX` (container image name prefix). The legacy `HOLOHUB_*` spelling is no longer honored in v1 — set the `HOLOSCAN_CLI_*` names directly. `holoscan env-info` lists every env var the CLI reads in the current shell. +Common env vars: `HOLOSCAN_CLI_ROOT` (repo root), `HOLOSCAN_CLI_SEARCH_PATH` (subdirs to scan for `metadata.json`), `HOLOSCAN_CLI_PATH_PREFIX` (placeholder prefix in metadata templates), `HOLOSCAN_CLI_REPO_PREFIX` (container image name prefix). The legacy `HOLOHUB_*` spelling is no longer honored since holoscan v4.3.0 — set the `HOLOSCAN_CLI_*` names directly. `holoscan env-info` lists every env var the CLI reads in the current shell. ## Source layout @@ -149,4 +149,4 @@ the workflow badges at the top of this page. ### HAP/MAP application packaging -Application packaging (HAP/MAP) is no longer part of this CLI: `holoscan nics` and the `monai-deploy` console script are intentionally not provided. The current `holoscan package` command is for building Holoscan Module distribution artifacts; it is not the legacy HAP/MAP application packager. The pre-v1 `holoscan run` was the HAP/MAP packaged-image runner; in v1 the same name now drives the HoloHub-style source-project runner, so it no longer launches packaged images. Developers that still rely on HAP/MAP packaging should pin `holoscan-cli<=4.2.0`, the last release that shipped that interface, or migrate to the Holoscan SDK packaging workflows directly. See [issue #164](https://github.com/nvidia-holoscan/holoscan-cli/issues/164) for the deprecation timeline. +Application packaging (HAP/MAP) is no longer part of this CLI: `holoscan nics` and the `monai-deploy` console script are intentionally not provided. The current `holoscan package` command is for building Holoscan Module distribution artifacts; it is not the legacy HAP/MAP application packager. Before holoscan v4.3.0, `holoscan run` was the HAP/MAP packaged-image runner; since v4.3.0 the same name now drives the HoloHub-style source-project runner, so it no longer launches packaged images. Developers that still rely on HAP/MAP packaging should pin `holoscan-cli<=4.2.0`, the last release that shipped that interface, or migrate to the Holoscan SDK packaging workflows directly. See [issue #164](https://github.com/nvidia-holoscan/holoscan-cli/issues/164) for the deprecation timeline. diff --git a/src/holoscan_cli/__main__.py b/src/holoscan_cli/__main__.py index f948b75..1a046df 100644 --- a/src/holoscan_cli/__main__.py +++ b/src/holoscan_cli/__main__.py @@ -44,17 +44,17 @@ LOG_LEVELS = ["DEBUG", "INFO", "WARN", "ERROR", "CRITICAL"] -# Subcommands removed in the source-project v1 cut. Mapped to a one-line note +# Subcommands removed since holoscan v4.3.0. Mapped to a one-line note # explaining what each one did, so users typing the old command get a specific -# message instead of argparse's generic "invalid choice". Note: the pre-v1 -# `holoscan run` was the HAP/MAP packaged-image runner; in v1 the same name is -# reused for the HoloHub-style source-project runner, so it is not listed here. +# message instead of argparse's generic "invalid choice". Note: the pre-4.3.0 +# `holoscan run` was the HAP/MAP packaged-image runner; since v4.3.0 the same +# name is reused for the HoloHub-style source-project runner, so it is not listed here. REMOVED_COMMANDS: dict[str, str] = { "nics": "the HAP NIC diagnostic command", } REMOVED_COMMAND_FOOTER = ( - "Removed HAP/MAP commands are out of scope for holoscan-cli v1. Pin " + "Removed HAP/MAP commands are not available since holoscan v4.3.0. Pin " "holoscan-cli<=4.2.0 if you still need that legacy command surface." ) @@ -179,7 +179,7 @@ def _exit_if_removed_command(argv: list[str]) -> None: return program = _program_name(argv) print( - f"Error: '{program} {command}' was removed in holoscan-cli v1 — " + f"Error: '{program} {command}' was removed since holoscan v4.3.0 — " f"{REMOVED_COMMANDS[command]} is no longer shipped.\n" f"{REMOVED_COMMAND_FOOTER}", file=sys.stderr, diff --git a/tests/unit/test_main.py b/tests/unit/test_main.py index dbd79f5..04c0964 100644 --- a/tests/unit/test_main.py +++ b/tests/unit/test_main.py @@ -259,8 +259,8 @@ def test_main_rejects_removed_commands(self, argv, command, capsys): # Exit 2 matches argparse's convention for unknown subcommands. assert excinfo.value.code == 2 err = capsys.readouterr().err - assert f"'holoscan {command}' was removed" in err - assert "Removed HAP/MAP commands are out of scope" in err + assert f"'holoscan {command}' was removed since holoscan v4.3.0" in err + assert "Removed HAP/MAP commands are not available since holoscan v4.3.0" in err def test_main_with_log_level(self): mock_args = MagicMock() From d89242b52b50888d98a46a4cac94aa58c62af465 Mon Sep 17 00:00:00 2001 From: Wenqi Li Date: Mon, 8 Jun 2026 09:20:14 +0100 Subject: [PATCH 2/3] fix: document SDK pin for legacy HAP/MAP packaging Co-authored-by: Codex --- README.md | 2 +- src/holoscan_cli/__main__.py | 2 +- tests/unit/test_main.py | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index c8b31d2..b897dfe 100644 --- a/README.md +++ b/README.md @@ -149,4 +149,4 @@ the workflow badges at the top of this page. ### HAP/MAP application packaging -Application packaging (HAP/MAP) is no longer part of this CLI: `holoscan nics` and the `monai-deploy` console script are intentionally not provided. The current `holoscan package` command is for building Holoscan Module distribution artifacts; it is not the legacy HAP/MAP application packager. Before holoscan v4.3.0, `holoscan run` was the HAP/MAP packaged-image runner; since v4.3.0 the same name now drives the HoloHub-style source-project runner, so it no longer launches packaged images. Developers that still rely on HAP/MAP packaging should pin `holoscan-cli<=4.2.0`, the last release that shipped that interface, or migrate to the Holoscan SDK packaging workflows directly. See [issue #164](https://github.com/nvidia-holoscan/holoscan-cli/issues/164) for the deprecation timeline. +Application packaging (HAP/MAP) is no longer part of this CLI: `holoscan nics` and the `monai-deploy` console script are intentionally not provided. The current `holoscan package` command is for building Holoscan Module distribution artifacts; it is not the legacy HAP/MAP application packager. Before holoscan v4.3.0, `holoscan run` was the HAP/MAP packaged-image runner; since v4.3.0 the same name now drives the HoloHub-style source-project runner, so it no longer launches packaged images. Developers that still rely on HAP/MAP packaging should pin both `holoscan-cli<=4.2.0`, the last CLI release that shipped that interface, and `holoscan<=4.2.0`, because the legacy package command depends on the artifacts JSON manifest and was only tested with those SDK versions. Otherwise, migrate to the Holoscan SDK packaging workflows directly. See [issue #164](https://github.com/nvidia-holoscan/holoscan-cli/issues/164) for the deprecation timeline. diff --git a/src/holoscan_cli/__main__.py b/src/holoscan_cli/__main__.py index 1a046df..baac3b0 100644 --- a/src/holoscan_cli/__main__.py +++ b/src/holoscan_cli/__main__.py @@ -55,7 +55,7 @@ REMOVED_COMMAND_FOOTER = ( "Removed HAP/MAP commands are not available since holoscan v4.3.0. Pin " - "holoscan-cli<=4.2.0 if you still need that legacy command surface." + "holoscan-cli<=4.2.0 and holoscan<=4.2.0 if you still need that legacy command surface." ) diff --git a/tests/unit/test_main.py b/tests/unit/test_main.py index 04c0964..3ea89e4 100644 --- a/tests/unit/test_main.py +++ b/tests/unit/test_main.py @@ -261,6 +261,7 @@ def test_main_rejects_removed_commands(self, argv, command, capsys): err = capsys.readouterr().err assert f"'holoscan {command}' was removed since holoscan v4.3.0" in err assert "Removed HAP/MAP commands are not available since holoscan v4.3.0" in err + assert "holoscan-cli<=4.2.0 and holoscan<=4.2.0" in err def test_main_with_log_level(self): mock_args = MagicMock() From efb20070b7da6f3f549356def69e16226c0012ff Mon Sep 17 00:00:00 2001 From: Wenqi Li Date: Mon, 8 Jun 2026 09:32:14 +0100 Subject: [PATCH 3/3] fix: wrap HAP MAP deprecation note Co-authored-by: Codex --- README.md | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index b897dfe..965e6c1 100644 --- a/README.md +++ b/README.md @@ -149,4 +149,16 @@ the workflow badges at the top of this page. ### HAP/MAP application packaging -Application packaging (HAP/MAP) is no longer part of this CLI: `holoscan nics` and the `monai-deploy` console script are intentionally not provided. The current `holoscan package` command is for building Holoscan Module distribution artifacts; it is not the legacy HAP/MAP application packager. Before holoscan v4.3.0, `holoscan run` was the HAP/MAP packaged-image runner; since v4.3.0 the same name now drives the HoloHub-style source-project runner, so it no longer launches packaged images. Developers that still rely on HAP/MAP packaging should pin both `holoscan-cli<=4.2.0`, the last CLI release that shipped that interface, and `holoscan<=4.2.0`, because the legacy package command depends on the artifacts JSON manifest and was only tested with those SDK versions. Otherwise, migrate to the Holoscan SDK packaging workflows directly. See [issue #164](https://github.com/nvidia-holoscan/holoscan-cli/issues/164) for the deprecation timeline. +Application packaging (HAP/MAP) is no longer part of this CLI: `holoscan nics` +and the `monai-deploy` console script are intentionally not provided. The current +`holoscan package` command is for building Holoscan Module distribution artifacts; +it is not the legacy HAP/MAP application packager. Before holoscan v4.3.0, +`holoscan run` was the HAP/MAP packaged-image runner; since v4.3.0 the same name +now drives the HoloHub-style source-project runner, so it no longer launches +packaged images. Developers that still rely on HAP/MAP packaging should pin both +`holoscan-cli<=4.2.0`, the last CLI release that shipped that interface, and +`holoscan<=4.2.0`, because the legacy package command depends on the artifacts +JSON manifest and was only tested with those SDK versions. Otherwise, migrate to +the Holoscan SDK packaging workflows directly. See +[issue #164](https://github.com/nvidia-holoscan/holoscan-cli/issues/164) for the +deprecation timeline.