Create a CTPToolResult quickly.
(call_id, tool, result=None, error=None)
| 691 | |
| 692 | |
| 693 | def _make_tool_result(call_id, tool, result=None, error=None): |
| 694 | """Create a CTPToolResult quickly.""" |
| 695 | now = datetime.now(UTC) |
| 696 | return CTPToolResult( |
| 697 | id=call_id, |
| 698 | tool=tool, |
| 699 | result=result, |
| 700 | error=error, |
| 701 | start_time=now, |
| 702 | end_time=now, |
| 703 | machine=platform.node(), |
| 704 | pid=os.getpid(), |
| 705 | ) |
| 706 | |
| 707 | |
| 708 | def _make_processor(tool_manager=None, ui_manager=None, context=None): |
nothing calls this directly
no outgoing calls
no test coverage detected