Skip to content

Commit c9b7e7c

Browse files
authored
Fix CLI hyperlink wrapping that breaks CMD-click (#4318)
1 parent 46f4c2d commit c9b7e7c

File tree

3 files changed

+12
-5
lines changed

3 files changed

+12
-5
lines changed

src/zenml/cli/deployment.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,8 @@ def provision_deployment(
272272
dashboard_url = get_deployment_url(deployment)
273273
if dashboard_url:
274274
cli_utils.declare(
275-
f"\nView in ZenML Cloud: [link]{dashboard_url}[/link]"
275+
f"\nView in ZenML Cloud: [link]{dashboard_url}[/link]",
276+
no_wrap=True,
276277
)
277278

278279

src/zenml/cli/pipeline.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -491,7 +491,8 @@ def deploy_pipeline(
491491
dashboard_url = get_deployment_url(deployment)
492492
if dashboard_url:
493493
cli_utils.declare(
494-
f"\nView in the ZenML UI: [link]{dashboard_url}[/link]"
494+
f"\nView in the ZenML UI: [link]{dashboard_url}[/link]",
495+
no_wrap=True,
495496
)
496497

497498
if attach:
@@ -1272,7 +1273,8 @@ def deploy_snapshot(
12721273
dashboard_url = get_deployment_url(deployment)
12731274
if dashboard_url:
12741275
cli_utils.declare(
1275-
f"\nView in the ZenML UI: [link]{dashboard_url}[/link]"
1276+
f"\nView in the ZenML UI: [link]{dashboard_url}[/link]",
1277+
no_wrap=True,
12761278
)
12771279

12781280

src/zenml/cli/utils.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2363,9 +2363,13 @@ def pretty_print_deployment(
23632363
if deployment.url:
23642364
declare("\n[bold]Connection information:[/bold]")
23652365

2366-
declare(f"\n[bold]Endpoint URL:[/bold] [link]{deployment.url}[/link]")
23672366
declare(
2368-
f"[bold]Swagger URL:[/bold] [link]{deployment.url.rstrip('/')}/docs[/link]"
2367+
f"\n[bold]Endpoint URL:[/bold] [link]{deployment.url}[/link]",
2368+
no_wrap=True,
2369+
)
2370+
declare(
2371+
f"[bold]Swagger URL:[/bold] [link]{deployment.url.rstrip('/')}/docs[/link]",
2372+
no_wrap=True,
23692373
)
23702374

23712375
# Auth key handling with proper security

0 commit comments

Comments
 (0)