.
This commit is contained in:
@@ -8,7 +8,10 @@ dependencies = [
|
||||
"fastapi>=0.121.3",
|
||||
"playwright>=1.56.0",
|
||||
"pydantic>=2.12.4",
|
||||
"pydantic-settings>=2.4.0",
|
||||
"python-dotenv>=1.2.1",
|
||||
"pyyaml>=6.0.2",
|
||||
"uvicorn>=0.30.6",
|
||||
]
|
||||
|
||||
[dependency-groups]
|
||||
|
||||
@@ -1,5 +1,20 @@
|
||||
def main():
|
||||
print("Hello from demos!")
|
||||
import os
|
||||
|
||||
from guide.app.main import app, create_app
|
||||
|
||||
|
||||
def main() -> None:
|
||||
"""Run a development server if uvicorn is available."""
|
||||
try:
|
||||
import uvicorn # type: ignore
|
||||
except ModuleNotFoundError: # pragma: no cover - runtime convenience only
|
||||
raise SystemExit(
|
||||
"uvicorn is required to run the server. Install with `pip install uvicorn`."
|
||||
)
|
||||
|
||||
host = os.getenv("HOST", "0.0.0.0")
|
||||
port = int(os.getenv("PORT", "8000"))
|
||||
uvicorn.run("guide.main:app", host=host, port=port, reload=False)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
Reference in New Issue
Block a user