heiyuheiyu commited on
Commit
e836842
·
verified ·
1 Parent(s): 10ac91a

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -2
Dockerfile CHANGED
@@ -149,8 +149,12 @@ def restore():
149
 
150
  if not flag_exists and not force_restore:
151
  print("Restore skip: initialized.flag not found, this is first deploy or rebuild.")
152
- client.put_file(INIT_FLAG, b'')
153
- print(f"[OK] Uploaded {INIT_FLAG} to dataset")
 
 
 
 
154
  return
155
 
156
  if force_restore:
 
149
 
150
  if not flag_exists and not force_restore:
151
  print("Restore skip: initialized.flag not found, this is first deploy or rebuild.")
152
+ client = get_dataset_client()
153
+ try:
154
+ client.put_file(INIT_FLAG, b'')
155
+ print(f"[OK] Uploaded {INIT_FLAG} to dataset")
156
+ except Exception as e:
157
+ print(f"[Warn] Failed to upload {INIT_FLAG}: {e}")
158
  return
159
 
160
  if force_restore: