| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
- Import NOT_GIVEN in agents.py to fix NameError in custom create_task/cancel_task helpers - Convert tests.utils imports to relative imports so pyright can resolve them Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
The custom create_task/cancel_task/send_message/send_event helpers reference CreateTaskResponse, CancelTaskResponse, SendMessageResponse, SendMessageStreamResponse, and SendEventResponse but only AgentRpcResponse was imported, causing NameError at runtime. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
| Back | FazBrowse Home | New Git URL |
Summary
Test plan
🤖 Generated with Claude Code
Greptile Summary
This PR resolves two categories of lint/test failures introduced by recently added custom RPC helper endpoints. It adds the missing NOT_GIVEN sentinel import and expands the agent_rpc_response import block in agents.py, and converts three test files from absolute tests.utils imports to relative imports matching the project convention.
Confidence Score: 5/5
All changes are targeted import fixes with no logic changes; the custom RPC helper methods themselves are untouched and tests pass.
The diff is entirely mechanical: one missing sentinel is added to an import line, six names are added to an all list, and three test files switch from absolute to relative imports. No behaviour changes are introduced, the test suite and pyright both pass per the PR description, and the patterns used match the rest of the codebase.
No files require special attention.
Important Files Changed
Sequence Diagram
sequenceDiagram participant Caller participant AgentsResource participant rpc / rpc_by_name participant agent_rpc_response Caller->>AgentsResource: create_task(agent_id, params) AgentsResource->>rpc / rpc_by_name: method="task/create", id=NOT_GIVEN, jsonrpc=NOT_GIVEN rpc / rpc_by_name-->>AgentsResource: AgentRpcResponse AgentsResource->>agent_rpc_response: CreateTaskResponse.model_validate(...) agent_rpc_response-->>Caller: CreateTaskResponse Caller->>AgentsResource: cancel_task(agent_name, params) AgentsResource->>rpc / rpc_by_name: method="task/cancel" rpc / rpc_by_name-->>AgentsResource: AgentRpcResponse AgentsResource->>agent_rpc_response: CancelTaskResponse.model_validate(...) agent_rpc_response-->>Caller: CancelTaskResponse Caller->>AgentsResource: send_message(agent_id, params) AgentsResource->>rpc / rpc_by_name: method="message/send" (streaming) rpc / rpc_by_name-->>AgentsResource: SSE stream AgentsResource->>agent_rpc_response: SendMessageResponse / SendMessageStreamResponse agent_rpc_response-->>Caller: SendMessageResponseReviews (3): Last reviewed commit: "fix: sort imports in agents resource" | Re-trigger Greptile