diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index 5c6f32f80..1f3497a0f 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -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: diff --git a/backend/packages/harness/deerflow/agents/middlewares/sandbox_audit_middleware.py b/backend/packages/harness/deerflow/agents/middlewares/sandbox_audit_middleware.py index e41f5912a..ad7d02357 100644 --- a/backend/packages/harness/deerflow/agents/middlewares/sandbox_audit_middleware.py +++ b/backend/packages/harness/deerflow/agents/middlewares/sandbox_audit_middleware.py @@ -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 diff --git a/backend/tests/test_gateway_runtime_cleanup.py b/backend/tests/test_gateway_runtime_cleanup.py index 145ef0eab..7574124c0 100644 --- a/backend/tests/test_gateway_runtime_cleanup.py +++ b/backend/tests/test_gateway_runtime_cleanup.py @@ -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