Spaces:
Sleeping
Sleeping
fix: add uv.lock, server/app.py, project.scripts, and openenv-core dependency
Browse files- pyproject.toml +4 -0
- server/app.py +18 -0
- uv.lock +0 -0
pyproject.toml
CHANGED
|
@@ -12,4 +12,8 @@ dependencies = [
|
|
| 12 |
"fastapi>=0.110.0",
|
| 13 |
"uvicorn>=0.29.0",
|
| 14 |
"pyyaml>=6.0",
|
|
|
|
| 15 |
]
|
|
|
|
|
|
|
|
|
|
|
|
| 12 |
"fastapi>=0.110.0",
|
| 13 |
"uvicorn>=0.29.0",
|
| 14 |
"pyyaml>=6.0",
|
| 15 |
+
"openenv-core>=0.2.0",
|
| 16 |
]
|
| 17 |
+
|
| 18 |
+
[project.scripts]
|
| 19 |
+
server = "app:app"
|
server/app.py
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""
|
| 2 |
+
server/app.py – Entry point for multi-mode deployment.
|
| 3 |
+
|
| 4 |
+
Re-exports the FastAPI app from the parent package so the server can be
|
| 5 |
+
started from either the repo root or the server/ subdirectory.
|
| 6 |
+
"""
|
| 7 |
+
|
| 8 |
+
import os
|
| 9 |
+
import sys
|
| 10 |
+
|
| 11 |
+
# Allow imports from the repo root regardless of working directory
|
| 12 |
+
sys.path.insert(0, os.path.join(os.path.dirname(__file__), ".."))
|
| 13 |
+
|
| 14 |
+
from app import app # noqa: F401 — re-export for uvicorn
|
| 15 |
+
|
| 16 |
+
if __name__ == "__main__":
|
| 17 |
+
import uvicorn
|
| 18 |
+
uvicorn.run("server.app:app", host="0.0.0.0", port=7860, reload=False)
|
uv.lock
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|