mirror of
https://github.com/bytedance/deer-flow.git
synced 2026-07-21 10:15:47 +00:00
Follow-up to #3301 / #3344. The Gateway-embedded runtime is the standard topology — there is no standalone LangGraph service — but two stale references slipped past the cleanup guard: - .github/copilot-instructions.md still told contributors that `make dev` "Starts LangGraph (2024)" and wrote logs/langgraph.log. - SandboxAuditMiddleware's docstring pointed audit logs at langgraph.log. Update both to the Gateway-embedded reality (gateway.log) and extend test_gateway_runtime_cleanup.py to pin the agent-instruction docs so the standalone references can't reappear. Stays within the safe scope of #3304: does not touch langgraph_auth.py, langgraph.json, or the langgraph-api / langgraph-cli / langgraph-runtime-inmem deps, which the issue gates on maintainer confirmation of Studio / direct LangGraph Server support.
This commit is contained in:
@@ -94,9 +94,9 @@ make dev
|
||||
Behavior:
|
||||
|
||||
- Stops existing local services first.
|
||||
- Starts LangGraph (`2024`), Gateway (`8001`), Frontend (`3000`), nginx (`2026`).
|
||||
- Starts Gateway (`8001`, with the embedded LangGraph-compatible runtime), Frontend (`3000`), nginx (`2026`). There is no standalone LangGraph service.
|
||||
- Unified app endpoint: `http://localhost:2026`.
|
||||
- Logs: `logs/langgraph.log`, `logs/gateway.log`, `logs/frontend.log`, `logs/nginx.log`.
|
||||
- Logs: `logs/gateway.log`, `logs/frontend.log`, `logs/nginx.log`.
|
||||
|
||||
Stop services:
|
||||
|
||||
|
||||
@@ -201,7 +201,7 @@ class SandboxAuditMiddleware(AgentMiddleware[ThreadState]):
|
||||
1. **Command classification**: regex + shlex analysis grades commands as
|
||||
high-risk (block), medium-risk (warn), or safe (pass).
|
||||
2. **Audit log**: every bash call is recorded as a structured JSON entry
|
||||
via the standard logger (visible in langgraph.log).
|
||||
via the standard logger (visible in gateway.log).
|
||||
|
||||
High-risk commands (e.g. ``rm -rf /``, ``curl url | bash``) are blocked:
|
||||
the handler is not called and an error ``ToolMessage`` is returned so the
|
||||
|
||||
@@ -147,3 +147,14 @@ def test_gateway_runtime_docs_do_not_reference_transition_modes():
|
||||
assert "./scripts/deploy.sh --gateway" not in content, path
|
||||
assert "docker compose --profile gateway" not in content, path
|
||||
assert "`/api/langgraph/*` → LangGraph" not in content, path
|
||||
|
||||
|
||||
def test_agent_instruction_docs_do_not_reference_standalone_langgraph_server():
|
||||
"""Agent/Copilot instruction docs must describe only the Gateway-embedded
|
||||
runtime — no standalone LangGraph service, port 2024, or langgraph.log."""
|
||||
content = _read(".github/copilot-instructions.md")
|
||||
|
||||
assert "langgraph.log" not in content
|
||||
assert "localhost:2024" not in content
|
||||
assert "127.0.0.1:2024" not in content
|
||||
assert "Starts LangGraph" not in content
|
||||
|
||||
Reference in New Issue
Block a user