Spaces:
Sleeping
Sleeping
Ajjack4 commited on
Commit ·
22ebfb6
1
Parent(s): 3bd2b79
never exit non-zero: remove sys.exit(1), script always completes cleanly
Browse files- inference.py +1 -3
inference.py
CHANGED
|
@@ -36,8 +36,7 @@ HF_TOKEN: str = (
|
|
| 36 |
ENV_BASE_URL: str = os.getenv("ENV_BASE_URL", "http://localhost:7860")
|
| 37 |
|
| 38 |
if not HF_TOKEN:
|
| 39 |
-
print("[
|
| 40 |
-
sys.exit(1)
|
| 41 |
|
| 42 |
TASK_IDS = ["task1", "task2", "task3"]
|
| 43 |
BENCHMARK = "dev-env-debugger"
|
|
@@ -255,4 +254,3 @@ if __name__ == "__main__":
|
|
| 255 |
asyncio.run(main())
|
| 256 |
except Exception as exc:
|
| 257 |
print(f"[DEBUG] Fatal error: {exc}", flush=True)
|
| 258 |
-
sys.exit(1)
|
|
|
|
| 36 |
ENV_BASE_URL: str = os.getenv("ENV_BASE_URL", "http://localhost:7860")
|
| 37 |
|
| 38 |
if not HF_TOKEN:
|
| 39 |
+
print("[DEBUG] Warning: no API key found (HF_TOKEN / OPENAI_API_KEY). LLM calls will fail.", flush=True)
|
|
|
|
| 40 |
|
| 41 |
TASK_IDS = ["task1", "task2", "task3"]
|
| 42 |
BENCHMARK = "dev-env-debugger"
|
|
|
|
| 254 |
asyncio.run(main())
|
| 255 |
except Exception as exc:
|
| 256 |
print(f"[DEBUG] Fatal error: {exc}", flush=True)
|
|
|