🔧 fix: Catch Errors in ToolEndHandler and Pass Logger (#10565)
Some checks are pending
Docker Dev Branch Images Build / build (Dockerfile, lc-dev, node) (push) Waiting to run
Docker Dev Branch Images Build / build (Dockerfile.multi, lc-dev-api, api-build) (push) Waiting to run

This commit is contained in:
Danny Avila 2025-11-18 13:00:33 -05:00 committed by GitHub
parent 3dd827e9d2
commit 8f887f480d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 8 additions and 8 deletions

View file

@ -47,7 +47,7 @@
"@langchain/google-genai": "^0.2.13", "@langchain/google-genai": "^0.2.13",
"@langchain/google-vertexai": "^0.2.13", "@langchain/google-vertexai": "^0.2.13",
"@langchain/textsplitters": "^0.1.0", "@langchain/textsplitters": "^0.1.0",
"@librechat/agents": "^3.0.20", "@librechat/agents": "^3.0.21",
"@librechat/api": "*", "@librechat/api": "*",
"@librechat/data-schemas": "*", "@librechat/data-schemas": "*",
"@microsoft/microsoft-graph-client": "^3.0.7", "@microsoft/microsoft-graph-client": "^3.0.7",

View file

@ -162,7 +162,7 @@ function getDefaultHandlers({ res, aggregateContent, toolEndCallback, collectedU
} }
const handlers = { const handlers = {
[GraphEvents.CHAT_MODEL_END]: new ModelEndHandler(collectedUsage), [GraphEvents.CHAT_MODEL_END]: new ModelEndHandler(collectedUsage),
[GraphEvents.TOOL_END]: new ToolEndHandler(toolEndCallback), [GraphEvents.TOOL_END]: new ToolEndHandler(toolEndCallback, logger),
[GraphEvents.CHAT_MODEL_STREAM]: new ChatModelStreamHandler(), [GraphEvents.CHAT_MODEL_STREAM]: new ChatModelStreamHandler(),
[GraphEvents.ON_RUN_STEP]: { [GraphEvents.ON_RUN_STEP]: {
/** /**

10
package-lock.json generated
View file

@ -63,7 +63,7 @@
"@langchain/google-genai": "^0.2.13", "@langchain/google-genai": "^0.2.13",
"@langchain/google-vertexai": "^0.2.13", "@langchain/google-vertexai": "^0.2.13",
"@langchain/textsplitters": "^0.1.0", "@langchain/textsplitters": "^0.1.0",
"@librechat/agents": "^3.0.20", "@librechat/agents": "^3.0.21",
"@librechat/api": "*", "@librechat/api": "*",
"@librechat/data-schemas": "*", "@librechat/data-schemas": "*",
"@microsoft/microsoft-graph-client": "^3.0.7", "@microsoft/microsoft-graph-client": "^3.0.7",
@ -16351,9 +16351,9 @@
} }
}, },
"node_modules/@librechat/agents": { "node_modules/@librechat/agents": {
"version": "3.0.20", "version": "3.0.21",
"resolved": "https://registry.npmjs.org/@librechat/agents/-/agents-3.0.20.tgz", "resolved": "https://registry.npmjs.org/@librechat/agents/-/agents-3.0.21.tgz",
"integrity": "sha512-GSFpTYIylN/01c4QksMlsKBkptB4v9qYHzcT7rXxHzj568W7mz0ZPBfs1N6PwZRyp+1RgDwo3v38CS4oQmdOTQ==", "integrity": "sha512-IZmq0Z5xplBHk2bHTM85h3222OCh5/doYvmVLyYtSjjvoSa3HDsTMxDtYUV5bs0wRIqddrRslq6qwDN7/UWuvQ==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@langchain/anthropic": "^0.3.26", "@langchain/anthropic": "^0.3.26",
@ -47334,7 +47334,7 @@
"@azure/storage-blob": "^12.27.0", "@azure/storage-blob": "^12.27.0",
"@keyv/redis": "^4.3.3", "@keyv/redis": "^4.3.3",
"@langchain/core": "^0.3.79", "@langchain/core": "^0.3.79",
"@librechat/agents": "^3.0.20", "@librechat/agents": "^3.0.21",
"@librechat/data-schemas": "*", "@librechat/data-schemas": "*",
"@modelcontextprotocol/sdk": "^1.21.0", "@modelcontextprotocol/sdk": "^1.21.0",
"axios": "^1.12.1", "axios": "^1.12.1",

View file

@ -84,7 +84,7 @@
"@azure/storage-blob": "^12.27.0", "@azure/storage-blob": "^12.27.0",
"@keyv/redis": "^4.3.3", "@keyv/redis": "^4.3.3",
"@langchain/core": "^0.3.79", "@langchain/core": "^0.3.79",
"@librechat/agents": "^3.0.20", "@librechat/agents": "^3.0.21",
"@librechat/data-schemas": "*", "@librechat/data-schemas": "*",
"@modelcontextprotocol/sdk": "^1.21.0", "@modelcontextprotocol/sdk": "^1.21.0",
"axios": "^1.12.1", "axios": "^1.12.1",