Skip to content

Commit 70d717c

Browse files
Bordalantiga
authored andcommitted
switch download UI from GCP to S3 (#18643)
(cherry picked from commit f83917d)
1 parent 2a0af04 commit 70d717c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

.actions/assistant.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ def distribute_version(src_folder: str, ver_file: str = "version.info") -> None:
212212
shutil.copy2(ver_template, fpath)
213213

214214

215-
def _download_frontend(pkg_path: str):
215+
def _download_frontend(pkg_path: str, version: str = "v0.0.0"):
216216
"""Downloads an archive file for a specific release of the Lightning frontend and extracts it to the correct
217217
directory."""
218218

@@ -222,13 +222,13 @@ def _download_frontend(pkg_path: str):
222222

223223
shutil.rmtree(frontend_dir, ignore_errors=True)
224224
# TODO: remove this once lightning-ui package is ready as a dependency
225-
frontend_release_url = "https://storage.googleapis.com/grid-packages/lightning-ui/v0.0.0/build.tar.gz"
225+
frontend_release_url = f"https://lightning-packages.s3.amazonaws.com/ui/{version}.tar.gz"
226226
response = urllib.request.urlopen(frontend_release_url)
227227

228228
file = tarfile.open(fileobj=response, mode="r|gz")
229229
file.extractall(path=download_dir)
230230

231-
shutil.move(os.path.join(download_dir, "build"), frontend_dir)
231+
shutil.move(download_dir, frontend_dir)
232232
print("The Lightning UI has successfully been downloaded!")
233233

234234
# If installing from source without internet connection, we don't want to break the installation

0 commit comments

Comments
 (0)