Commit 4a4309b
authored
fix(cli): standardize error and warning messages (#305)
* fix(cli): standardize error and warning message formatting
Add print_error/print_warning helpers to cli/utils/formatting.py and
replace all inline error/warning prints across 9 CLI command files.
Consistent "Error:"/"Warning:" prefix capitalization and leading blank
line for visual separation from surrounding output.
AE-2436
* fix(cli): address PR feedback on redundant error prefixes
Remove redundant "Error"/"error" from messages passed to print_error()
since the helper already adds the "Error:" prefix. Fix undeploy exit
code from 0 to 1 when invoked without required arguments.
* fix(cli): address review findings on error message helpers
- Remove unconditional \n prefix from print_error/print_warning; restore
leading newline only at the 5 call sites that originally had it
- Remove unrelated docs/plans files and revert uv.lock
- Fix import ordering in undeploy.py (third-party before first-party)
- Add logger.exception() to run_command broad except and
logger.warning() to provisioning failure for traceback capture
- Add unit tests for print_error/print_warning helpers
- Add exit_code assertion guarding undeploy Exit(1) fix
* fix(cli): strip leading newlines from error/warning messages
Addresses review feedback: embedded \n in print_error/print_warning
message args produced "Error:\n<msg>" instead of "\nError: <msg>".
Formatting helpers now lstrip() the message defensively, call sites
use console.print() for vertical spacing. Drops redundant "SSL error:"
label in deploy error handler.1 parent 2b4e4c1 commit 4a4309b
14 files changed
Lines changed: 186 additions & 980 deletions
File tree
- docs/plans
- src/runpod_flash/cli
- commands
- utils
- tests/unit/cli
- utils
This file was deleted.
0 commit comments