From 571a7e40e40fa2f6d2d373b0a7b9acc55df22a43 Mon Sep 17 00:00:00 2001 From: lihongyuan99 <64824864+lihongyuan99@users.noreply.github.com> Date: Fri, 2 Oct 2026 17:08:30 +0800 Subject: [PATCH] docs(harness): import the Gateway app from the module that defines it (#6169) Both the en and zh integration guides show `from deerflow.app.gateway.main import app`, but there is no deerflow.app package and no gateway/main.py in the tree: the FastAPI instance is created by create_app() and bound at module level in backend/app/gateway/app.py, which is also how backend/AGENTS.md documents it. The copy-pasteable snippet now names that module, so mounting the Gateway as a sub-application works from the documented import instead of failing at runtime. --- frontend/src/content/en/harness/integration-guide.mdx | 2 +- frontend/src/content/zh/harness/integration-guide.mdx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/content/en/harness/integration-guide.mdx b/frontend/src/content/en/harness/integration-guide.mdx index 5451668159..841b53786b 100644 --- a/frontend/src/content/en/harness/integration-guide.mdx +++ b/frontend/src/content/en/harness/integration-guide.mdx @@ -110,7 +110,7 @@ from fastapi import FastAPI app = FastAPI() # Mount the DeerFlow gateway router -from deerflow.app.gateway.main import app as gateway_app +from app.gateway.app import app as gateway_app app.mount("/deerflow", gateway_app) ``` diff --git a/frontend/src/content/zh/harness/integration-guide.mdx b/frontend/src/content/zh/harness/integration-guide.mdx index b86d3bda01..520f5df913 100644 --- a/frontend/src/content/zh/harness/integration-guide.mdx +++ b/frontend/src/content/zh/harness/integration-guide.mdx @@ -107,7 +107,7 @@ from fastapi import FastAPI app = FastAPI() # 挂载 DeerFlow Gateway -from deerflow.app.gateway.main import app as gateway_app +from app.gateway.app import app as gateway_app app.mount("/deerflow", gateway_app) ```