skypilot-nightly 1.0.0.dev20240825__py3-none-any.whl → 1.0.0.dev20240827__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
sky/__init__.py CHANGED
@@ -5,7 +5,7 @@ from typing import Optional
5
5
  import urllib.request
6
6
 
7
7
  # Replaced with the current commit when building the wheels.
8
- _SKYPILOT_COMMIT_SHA = '4e7478bcf4ef837ae749a183fd74ce04dabe0d62'
8
+ _SKYPILOT_COMMIT_SHA = 'c25d6eaf484ccc828fe944909a004450c175e859'
9
9
 
10
10
 
11
11
  def _get_git_commit():
@@ -35,7 +35,7 @@ def _get_git_commit():
35
35
 
36
36
 
37
37
  __commit__ = _get_git_commit()
38
- __version__ = '1.0.0.dev20240825'
38
+ __version__ = '1.0.0.dev20240827'
39
39
  __root_dir__ = os.path.dirname(os.path.abspath(__file__))
40
40
 
41
41
 
@@ -39,29 +39,30 @@ _WHEEL_PATTERN = (f'{_PACKAGE_WHEEL_NAME}-'
39
39
  f'{version.parse(sky.__version__)}-*.whl')
40
40
 
41
41
 
42
- def _get_latest_wheel_and_remove_all_others() -> pathlib.Path:
43
- wheel_name = (f'**/{_WHEEL_PATTERN}')
42
+ def _remove_stale_wheels(latest_wheel_dir: pathlib.Path) -> None:
43
+ """Remove all wheels except the latest one."""
44
+ for f in WHEEL_DIR.iterdir():
45
+ if f != latest_wheel_dir:
46
+ if f.is_dir() and not f.is_symlink():
47
+ shutil.rmtree(f, ignore_errors=True)
48
+
49
+
50
+ def _get_latest_wheel() -> pathlib.Path:
51
+ wheel_name = f'**/{_WHEEL_PATTERN}'
44
52
  try:
45
53
  latest_wheel = max(WHEEL_DIR.glob(wheel_name), key=os.path.getctime)
46
54
  except ValueError:
47
55
  raise FileNotFoundError(
48
56
  'Could not find built SkyPilot wheels with glob pattern '
49
57
  f'{wheel_name} under {WHEEL_DIR!r}') from None
50
-
51
- latest_wheel_dir_name = latest_wheel.parent
52
- # Cleanup older wheels.
53
- for f in WHEEL_DIR.iterdir():
54
- if f != latest_wheel_dir_name:
55
- if f.is_dir() and not f.is_symlink():
56
- shutil.rmtree(f, ignore_errors=True)
57
58
  return latest_wheel
58
59
 
59
60
 
60
- def _build_sky_wheel():
61
- """Build a wheel for SkyPilot."""
62
- with tempfile.TemporaryDirectory() as tmp_dir:
61
+ def _build_sky_wheel() -> pathlib.Path:
62
+ """Build a wheel for SkyPilot and return the path to the wheel."""
63
+ with tempfile.TemporaryDirectory() as tmp_dir_str:
63
64
  # prepare files
64
- tmp_dir = pathlib.Path(tmp_dir)
65
+ tmp_dir = pathlib.Path(tmp_dir_str)
65
66
  sky_tmp_dir = tmp_dir / 'sky'
66
67
  sky_tmp_dir.mkdir()
67
68
  for item in SKY_PACKAGE_PATH.iterdir():
@@ -129,6 +130,7 @@ def _build_sky_wheel():
129
130
  wheel_dir = WHEEL_DIR / hash_of_latest_wheel
130
131
  wheel_dir.mkdir(parents=True, exist_ok=True)
131
132
  shutil.move(str(wheel_path), wheel_dir)
133
+ return wheel_dir / wheel_path.name
132
134
 
133
135
 
134
136
  def build_sky_wheel() -> Tuple[pathlib.Path, str]:
@@ -161,13 +163,22 @@ def build_sky_wheel() -> Tuple[pathlib.Path, str]:
161
163
  last_modification_time = _get_latest_modification_time(SKY_PACKAGE_PATH)
162
164
  last_wheel_modification_time = _get_latest_modification_time(WHEEL_DIR)
163
165
 
164
- # only build wheels if the wheel is outdated
165
- if last_wheel_modification_time < last_modification_time:
166
+ # Only build wheels if the wheel is outdated or wheel does not exist
167
+ # for the requested version.
168
+ if (last_wheel_modification_time < last_modification_time) or not any(
169
+ WHEEL_DIR.glob(f'**/{_WHEEL_PATTERN}')):
166
170
  if not WHEEL_DIR.exists():
167
171
  WHEEL_DIR.mkdir(parents=True, exist_ok=True)
168
- _build_sky_wheel()
169
-
170
- latest_wheel = _get_latest_wheel_and_remove_all_others()
172
+ latest_wheel = _build_sky_wheel()
173
+ else:
174
+ latest_wheel = _get_latest_wheel()
175
+
176
+ # We remove all wheels except the latest one for garbage collection.
177
+ # Otherwise stale wheels will accumulate over time.
178
+ # TODO(romilb): If the user switches versions every alternate launch,
179
+ # the wheel will be rebuilt every time. At the risk of adding
180
+ # complexity, we can consider TTL caching wheels by version here.
181
+ _remove_stale_wheels(latest_wheel.parent)
171
182
 
172
183
  wheel_hash = latest_wheel.parent.name
173
184
 
@@ -110,8 +110,8 @@ def docker_start_cmds(
110
110
  '--cap-add=SYS_ADMIN',
111
111
  '--device=/dev/fuse',
112
112
  '--security-opt=apparmor:unconfined',
113
+ '--entrypoint=/bin/bash',
113
114
  image,
114
- 'bash',
115
115
  ]
116
116
  return ' '.join(docker_run)
117
117
 
@@ -65,8 +65,8 @@ def docker_start_cmds(
65
65
  '--cap-add=SYS_ADMIN',
66
66
  '--device=/dev/fuse',
67
67
  '--security-opt=apparmor:unconfined',
68
+ '--entrypoint=/bin/bash',
68
69
  image,
69
- 'bash',
70
70
  ]
71
71
  return ' '.join(docker_run)
72
72
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: skypilot-nightly
3
- Version: 1.0.0.dev20240825
3
+ Version: 1.0.0.dev20240827
4
4
  Summary: SkyPilot: An intercloud broker for the clouds
5
5
  Author: SkyPilot Team
6
6
  License: Apache 2.0
@@ -1,4 +1,4 @@
1
- sky/__init__.py,sha256=Xsw4aeSr5vw12FyGDpZcJ5ovuWrmo8r9aLK4ZRRpSDE,5588
1
+ sky/__init__.py,sha256=IuJBBxwaKLPWTNsVoqsjLJICWYOjJxqA56-pAKYXGC8,5588
2
2
  sky/authentication.py,sha256=PXKsabUKnvhoTNoNwZzo66qjCLAsuc5pQ8esVu0IYh8,20424
3
3
  sky/check.py,sha256=sqUCow5Gqqtp2ouk7tZ3whwDOK23wqyUJvcxMBsich8,9080
4
4
  sky/cli.py,sha256=XlgRr617B_yE2HV_nW01D_m5nWntW2GstutNrMp86UA,201504
@@ -33,7 +33,7 @@ sky/backends/backend_utils.py,sha256=k-DQ-xlQElzlb5KhoyoaySw8t36gmsWtgeR24TM23iw
33
33
  sky/backends/cloud_vm_ray_backend.py,sha256=EXrJdc2wqKlgPkIrKtF2GYLw-wW_U49HDb0CpaVlIMA,230185
34
34
  sky/backends/docker_utils.py,sha256=Hyw1YY20EyghhEbYx6O2FIMDcGkNzBzV9TM7LFynei8,8358
35
35
  sky/backends/local_docker_backend.py,sha256=H4GBo0KFUC_EEf-ziv1OUbfAkOI5BrwkYs9fYOxSoNw,16741
36
- sky/backends/wheel_utils.py,sha256=Kt2WOtVvOdw1DCx-wM5QydQoIMbqzcTcHvbbHa9DYY4,7297
36
+ sky/backends/wheel_utils.py,sha256=3QS4T_Ydvo4DbYhogtyADyNBEf04I6jUCL71M285shQ,7963
37
37
  sky/backends/monkey_patches/monkey_patch_ray_up.py,sha256=76-y2fCaE3JINj8lEwHT1eirYzCbpD8O1ySsysuGu8o,3450
38
38
  sky/benchmark/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
39
39
  sky/benchmark/benchmark_state.py,sha256=X8CXmuU9KgsDRhKedhFgjeRMUFWtQsjFs1qECvPG2yg,8723
@@ -105,7 +105,7 @@ sky/jobs/dashboard/templates/index.html,sha256=DBKMYEkkJ6sgLYod9ro7drgL8Y_neDsCx
105
105
  sky/provision/__init__.py,sha256=Ap-ujmdXavCg2tMB0akwSxHJF1eaR6F_hjiw2miWamk,6146
106
106
  sky/provision/common.py,sha256=E8AlSUFcn0FYQq1erNmoVfMAdsF9tP2yxfyk-9PLvQU,10286
107
107
  sky/provision/constants.py,sha256=DvHj3wpqdpaSBHMOGIfVWLLWGJoz0eOQAx73DwYMNEk,531
108
- sky/provision/docker_utils.py,sha256=CMHeQF9IAWcNfhkgYHDyXumcpaL3MY-MRxHTKjJ4P4g,18814
108
+ sky/provision/docker_utils.py,sha256=Z7vDUs9Yjqks_CsWrACcTgABIZuFi3EJVFwkU0WsdD0,18832
109
109
  sky/provision/instance_setup.py,sha256=n1Px_KOYZl7Rf1WLXrfTTHyqxyA8_5QTN9BNLjQRkgc,22427
110
110
  sky/provision/logging.py,sha256=yZWgejrFBhhRjAtvFu5N5bRXIMK5TuwNjp1vKQqz2pw,2103
111
111
  sky/provision/metadata_utils.py,sha256=LrxeV4wD2QPzNdXV_npj8q-pr35FatxBBjF_jSbpOT0,4013
@@ -194,7 +194,7 @@ sky/skylet/log_lib.pyi,sha256=AHMkW2DGK2erFovb3ToZWxRiYaATlzkxKb5J9pkgF2Y,4295
194
194
  sky/skylet/skylet.py,sha256=U9plr5hmhD9-Nyy0LMCymlE8DWtRXTFXQvfbFsS746Y,1153
195
195
  sky/skylet/subprocess_daemon.py,sha256=QLq-reWzFikHT_uBS8PPzIQZFQFLSSbbN3JGyjRynzs,1348
196
196
  sky/skylet/providers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
197
- sky/skylet/providers/command_runner.py,sha256=t_eIyXHAdjugsyJul5VhbG7-VkWJHmZ4jziW257Qajs,16355
197
+ sky/skylet/providers/command_runner.py,sha256=z60lOGeG07GwEdPYWvcXFbW615zyAz3FV4vFsKP8ULs,16373
198
198
  sky/skylet/providers/ibm/__init__.py,sha256=GXo5F9ztvs0qMDI_G9wM5KvzySfYugslJMHHAnBENRc,94
199
199
  sky/skylet/providers/ibm/node_provider.py,sha256=olNtCoCxjXTT-C_youwdQ9UF1DPgO8OVwDueotGFaJI,38280
200
200
  sky/skylet/providers/ibm/utils.py,sha256=63vhKqLLOhAZdibSp8VWWONeyCER9F6U2VLrSpzlizk,1292
@@ -270,9 +270,9 @@ sky/utils/kubernetes/k8s_gpu_labeler_job.yaml,sha256=KPqp23B-zQ2SZK03jdHeF9fLTog
270
270
  sky/utils/kubernetes/k8s_gpu_labeler_setup.yaml,sha256=VLKT2KKimZu1GDg_4AIlIt488oMQvhRZWwsj9vBbPUg,3812
271
271
  sky/utils/kubernetes/rsync_helper.sh,sha256=1ad-m4s8QTPxaBQxNIL8AGDfX4un6T0dxZgk-R7OLyE,154
272
272
  sky/utils/kubernetes/ssh_jump_lifecycle_manager.py,sha256=RFLJ3k7MR5UN4SKHykQ0lV9SgXumoULpKYIAt1vh-HU,6560
273
- skypilot_nightly-1.0.0.dev20240825.dist-info/LICENSE,sha256=emRJAvE7ngL6x0RhQvlns5wJzGI3NEQ_WMjNmd9TZc4,12170
274
- skypilot_nightly-1.0.0.dev20240825.dist-info/METADATA,sha256=G_C-q4tUdHTzTw03Te6npNjMdtPkylXVaPpf3VljFFw,18870
275
- skypilot_nightly-1.0.0.dev20240825.dist-info/WHEEL,sha256=Mdi9PDNwEZptOjTlUcAth7XJDFtKrHYaQMPulZeBCiQ,91
276
- skypilot_nightly-1.0.0.dev20240825.dist-info/entry_points.txt,sha256=StA6HYpuHj-Y61L2Ze-hK2IcLWgLZcML5gJu8cs6nU4,36
277
- skypilot_nightly-1.0.0.dev20240825.dist-info/top_level.txt,sha256=qA8QuiNNb6Y1OF-pCUtPEr6sLEwy2xJX06Bd_CrtrHY,4
278
- skypilot_nightly-1.0.0.dev20240825.dist-info/RECORD,,
273
+ skypilot_nightly-1.0.0.dev20240827.dist-info/LICENSE,sha256=emRJAvE7ngL6x0RhQvlns5wJzGI3NEQ_WMjNmd9TZc4,12170
274
+ skypilot_nightly-1.0.0.dev20240827.dist-info/METADATA,sha256=v0hByAA-2TBDpNM9KAiguU7zWbK56R38CIOjllaitos,18870
275
+ skypilot_nightly-1.0.0.dev20240827.dist-info/WHEEL,sha256=Mdi9PDNwEZptOjTlUcAth7XJDFtKrHYaQMPulZeBCiQ,91
276
+ skypilot_nightly-1.0.0.dev20240827.dist-info/entry_points.txt,sha256=StA6HYpuHj-Y61L2Ze-hK2IcLWgLZcML5gJu8cs6nU4,36
277
+ skypilot_nightly-1.0.0.dev20240827.dist-info/top_level.txt,sha256=qA8QuiNNb6Y1OF-pCUtPEr6sLEwy2xJX06Bd_CrtrHY,4
278
+ skypilot_nightly-1.0.0.dev20240827.dist-info/RECORD,,