Skip to content

Commit

Permalink
[UX] remove deprecated sky spot CLI and sky.spot_xxx API (#4171)
Browse files Browse the repository at this point in the history
  • Loading branch information
cg505 authored Jan 28, 2025
1 parent f4a5355 commit 3c9024a
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 30 deletions.
11 changes: 0 additions & 11 deletions sky/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,12 +106,6 @@ def set_proxy_env_var(proxy_var: str, urllib_var: Optional[str]):
from sky.execution import exec # pylint: disable=redefined-builtin
from sky.execution import launch
from sky.jobs import ManagedJobStatus
# TODO (zhwu): These imports are for backward compatibility, and spot APIs
# should be called with `sky.spot.xxx` instead. Remove in release 0.8.0
from sky.jobs.core import spot_cancel
from sky.jobs.core import spot_launch
from sky.jobs.core import spot_queue
from sky.jobs.core import spot_tail_logs
from sky.optimizer import Optimizer
from sky.optimizer import OptimizeTarget
from sky.resources import Resources
Expand Down Expand Up @@ -172,7 +166,6 @@ def set_proxy_env_var(proxy_var: str, urllib_var: Optional[str]):
# execution APIs
'launch',
'exec',
'spot_launch',
# core APIs
'status',
'start',
Expand All @@ -184,12 +177,8 @@ def set_proxy_env_var(proxy_var: str, urllib_var: Optional[str]):
'queue',
'cancel',
'tail_logs',
'spot_tail_logs',
'download_logs',
'job_status',
# core APIs Spot Job Management
'spot_queue',
'spot_cancel',
# core APIs Storage Management
'storage_ls',
'storage_delete',
Expand Down
19 changes: 0 additions & 19 deletions sky/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -3997,25 +3997,6 @@ def jobs_dashboard(port: Optional[int]):
click.echo('Exiting.')


# TODO(zhwu): Backward compatibility for the old `sky spot launch` command.
# It is now renamed to `sky jobs launch` and the old command is deprecated.
# Remove in v0.8.0.
@cli.group(cls=_NaturalOrderGroup)
def spot():
"""Alias for Managed Jobs CLI (default to managed spot jobs)."""
pass


_add_command_alias(jobs,
jobs_launch,
new_group=spot,
override_command_argument={'use_spot': True})
_add_command_alias(jobs, jobs_queue, new_group=spot)
_add_command_alias(jobs, jobs_logs, new_group=spot)
_add_command_alias(jobs, jobs_cancel, new_group=spot)
_add_command_alias(jobs, jobs_dashboard, new_group=spot)


@cli.group(cls=_NaturalOrderGroup)
def serve():
"""SkyServe CLI (multi-region, multi-cloud serving)."""
Expand Down

0 comments on commit 3c9024a

Please sign in to comment.