Spaces:
Sleeping
Sleeping
Update loader.py
Browse files
loader.py
CHANGED
|
@@ -10,13 +10,13 @@ import httpx
|
|
| 10 |
app = FastAPI()
|
| 11 |
|
| 12 |
# ===== Config (from Space Secrets) =====
|
| 13 |
-
SPACE_ID = os.getenv("PRIVATE_SPACE_ID")
|
| 14 |
HF_TOKEN = os.getenv("HF_TOKEN") # token with READ access
|
| 15 |
REVISION = os.getenv("REVISION", "main") # branch/tag/commit
|
| 16 |
# ======================================
|
| 17 |
|
| 18 |
if not SPACE_ID:
|
| 19 |
-
raise RuntimeError("Set PRIVATE_SPACE_ID
|
| 20 |
if not HF_TOKEN:
|
| 21 |
raise RuntimeError("Set HF_TOKEN (READ access to the private Space) in Settings → Repository secrets.")
|
| 22 |
|
|
|
|
| 10 |
app = FastAPI()
|
| 11 |
|
| 12 |
# ===== Config (from Space Secrets) =====
|
| 13 |
+
SPACE_ID = os.getenv("PRIVATE_SPACE_ID")
|
| 14 |
HF_TOKEN = os.getenv("HF_TOKEN") # token with READ access
|
| 15 |
REVISION = os.getenv("REVISION", "main") # branch/tag/commit
|
| 16 |
# ======================================
|
| 17 |
|
| 18 |
if not SPACE_ID:
|
| 19 |
+
raise RuntimeError("Set PRIVATE_SPACE_ID in Settings → Repository secrets.")
|
| 20 |
if not HF_TOKEN:
|
| 21 |
raise RuntimeError("Set HF_TOKEN (READ access to the private Space) in Settings → Repository secrets.")
|
| 22 |
|