Some checks failed
CLI Tests / test-cli (push) Has been cancelled
Cross-Node Transaction Testing / transaction-test (push) Has been cancelled
Deploy to Testnet / deploy-testnet (push) Has been cancelled
Documentation Validation / validate-docs (push) Has been cancelled
Documentation Validation / validate-policies-strict (push) Has been cancelled
Multi-Node Stress Testing / stress-test (push) Has been cancelled
Node Failover Simulation / failover-test (push) Has been cancelled
Security Scanning / security-scan (push) Has been cancelled
Python Tests / test-python (push) Failing after 1m34s
Added stub data returns and error handling across multiple CLI handlers to prevent training script failures when services are unavailable: - AI handlers: Return stub job data instead of sys.exit on errors, fix coordinator_url parameter handling, wrap task_data in proper structure for job submission - Agent SDK: Add complete stub implementation for create/register/list/status/capabilities - System handlers: Add graceful fall
14 lines
608 B
Python
14 lines
608 B
Python
"""Script command registration for the unified CLI."""
|
|
|
|
import argparse
|
|
|
|
from parser_context import ParserContext
|
|
|
|
|
|
def register(subparsers: argparse._SubParsersAction, ctx: ParserContext) -> None:
|
|
script_parser = subparsers.add_parser("script", help="Script execution and automation")
|
|
script_parser.add_argument("--run", action="store_true", help="Run a script file")
|
|
script_parser.add_argument("--file", help="Script file to execute")
|
|
script_parser.add_argument("--args", help="Arguments to pass to script")
|
|
script_parser.set_defaults(handler=ctx.handle_script_run)
|