cli: cleaner error handling
Deploy bin / deploy (push) Successful in 3s
Deploy, build and restart MASTER / deploy (push) Successful in 2s
Deploy agebd python package / deploy (push) Successful in 1s

This commit is contained in:
Benjamin Labrecque
2026-07-07 12:06:45 +02:00
parent 3a43a36f93
commit 72655335a6
+3 -10
View File
@@ -79,11 +79,7 @@ class ServiceCreator:
registry_old.write_to_config()
hla_names_old.write_to_config()
switch_branch(repo, original_branch)
if isinstance(e, UVError):
pass
else:
raise e
raise e
def _render_new_service_templates(
self,
@@ -131,12 +127,9 @@ class ServiceCreator:
logger.warning(result.stderr.strip())
except FileNotFoundError as e:
logger.error(
"The 'uv' command-line tool is not installed or not in your PATH.",
)
raise UVError from e
raise UVError("The 'uv' command-line tool is not installed or not in your PATH.") from e
except subprocess.CalledProcessError as e:
logger.error("'uv lock' failed to execute successfully.")
logger.error(f"Exit Code: {e.returncode}")
logger.error(f"Details:\n{e.stderr}")
raise UVError from e
raise UVError(e.stderr) from e