Bug: Reemplazar Exceptions en MCP por respuestas adecuadas. #2
Owner
```
[05/27/26 17:40:49] Error calling tool 'find_customer_by_identifier'
╭─────────── Traceback (most recent call last) ────────────╮
│ /app/.venv/lib/python3.14/site-packages/fastmcp/server/s │
│ erver.py:1162 in call_tool │
│ │
│ /app/.venv/lib/python3.14/site-packages/fastmcp/tools/ba │
│ se.py:373 in _run │
│ │
│ ... 5 frames hidden ... │
│ │
│ /app/.venv/lib/python3.14/site-packages/pydantic/type_ad │
│ apter.py:441 in validate_python │
│ │
│ /app/src/tryton_mcp/server.py:92 in │
│ find_customer_by_identifier │
│ │
│ 89 │ result = services.party.find_by_identifier(ide │
│ 90 │ │
│ 91 │ if result.is_error: │
│ ❱ 92 │ │ raise Exception(f"Customer with identifier │
│ 93 │ │
│ 94 │ return result.data │
│ 95 │
╰──────────────────────────────────────────────────────────╯
Exception: Customer with identifier 573016859278 not found.
````
```
[04/07/26 17:19:54] Error validating tool 'create_schedule'
╭─────────── Traceback (most recent call last) ────────────╮
│ /app/.venv/lib/python3.14/site-packages/fastmcp/server/s │
│ erver.py:1162 in call_tool │
│ │
│ /app/.venv/lib/python3.14/site-packages/fastmcp/tools/ba │
│ se.py:373 in _run │
│ │
│ ... 4 frames hidden ... │
│ │
│ /app/.venv/lib/python3.14/site-packages/anyio/_backends/ │
│ _asyncio.py:1002 in run │
│ │
│ 999 │ │ │ │ │ exception: BaseException | No │
│ 1000 │ │ │ │ │ threadlocals.current_cancel_s │
│ 1001 │ │ │ │ │ try: │
│ ❱ 1002 │ │ │ │ │ │ result = context.run(func │
│ 1003 │ │ │ │ │ except BaseException as exc: │
│ 1004 │ │ │ │ │ │ exception = exc │
│ 1005 │ │ │ │ │ finally: │
│ │
│ /app/.venv/lib/python3.14/site-packages/pydantic/type_ad │
│ apter.py:441 in validate_python │
╰──────────────────────────────────────────────────────────╯
ValidationError: 1 validation error for
call[create_schedule]
professional
Input should be a valid integer [type=int_type,
input_value=None, input_type=NoneType]
```
```
[05/22/26 00:48:48] Error calling tool 'find_service_centers'
╭─────────── Traceback (most recent call last) ────────────╮
│ /app/.venv/lib/python3.14/site-packages/fastmcp/server/s │
│ erver.py:1162 in call_tool │
│ │
│ /app/.venv/lib/python3.14/site-packages/fastmcp/tools/ba │
│ se.py:373 in _run │
│ │
│ ... 5 frames hidden ... │
│ │
│ /app/.venv/lib/python3.14/site-packages/pydantic/type_ad │
│ apter.py:441 in validate_python │
│ │
│ /app/src/tryton_mcp/server.py:143 in │
│ find_service_centers │
│ │
│ 140 │ result = services.service_center.find_all(offs │
│ 141 │ │
│ 142 │ if result.is_error: │
│ ❱ 143 │ │ raise Exception(f"Failed to find service c │
│ 144 │ │
│ 145 │ return result.data │
│ 146 │
╰──────────────────────────────────────────────────────────╯
Exception: Failed to find service centers: cannot access
local variable 'response' where it is not associated with a
value
```
Bug
label
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?