Spaces:
Runtime error
Runtime error
fix: install requests at runtime before launching conversation-loop
Browse filesDockerfile layer cache may not pick up the new dependency. Install
requests via pip at runtime as a fallback to guarantee availability.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- scripts/sync_hf.py +4 -0
scripts/sync_hf.py
CHANGED
|
@@ -783,6 +783,10 @@ def main():
|
|
| 783 |
"""Launch conversation-loop with auto-restart on crash."""
|
| 784 |
nonlocal conv_loop_proc
|
| 785 |
time.sleep(60) # let OpenClaw fully initialize
|
|
|
|
|
|
|
|
|
|
|
|
|
| 786 |
script = os.path.join(os.path.dirname(__file__), "conversation-loop.py")
|
| 787 |
if not os.path.exists(script):
|
| 788 |
print(f"[SYNC] conversation-loop.py not found at {script}")
|
|
|
|
| 783 |
"""Launch conversation-loop with auto-restart on crash."""
|
| 784 |
nonlocal conv_loop_proc
|
| 785 |
time.sleep(60) # let OpenClaw fully initialize
|
| 786 |
+
# Ensure requests is installed (may be missing from Docker image)
|
| 787 |
+
subprocess.run([sys.executable, "-m", "pip", "install", "-q",
|
| 788 |
+
"--break-system-packages", "requests"],
|
| 789 |
+
capture_output=True, timeout=60)
|
| 790 |
script = os.path.join(os.path.dirname(__file__), "conversation-loop.py")
|
| 791 |
if not os.path.exists(script):
|
| 792 |
print(f"[SYNC] conversation-loop.py not found at {script}")
|