nvflare.tool.cli_session module

CLI-scoped session helpers.

add_startup_kit_selection_args(parser) None[source]

Add non-mutating startup-kit selectors to an online command parser.

new_active_cli_session(timeout: float, study: str = 'default', debug: bool = False) Session[source]

Create a CLI session using NVFLARE_STARTUP_KIT_DIR or the active registered startup kit.

new_cli_session(username: str, startup_kit_location: str, timeout: float, study: str = 'default', secure_mode: bool = True, debug: bool = False) Session[source]

Compatibility wrapper for CLI callers around the shared secure session factory.

new_cli_session_for_args(args=None, timeout: float = 5.0, study: str = 'default', debug: bool = False) Session[source]

Create a CLI session using per-command selectors, env var, or the active registered startup kit.

resolve_admin_user_and_dir_for_args(args=None)[source]

Resolve the admin identity and startup-kit directory for a command invocation.

resolve_startup_kit_dir_for_args(args=None) str[source]

Resolve per-command startup-kit selectors, falling back to env/active config.

resolve_startup_kit_info_for_args(args=None) dict[source]

Resolve startup-kit selection metadata for machine-readable command output.