Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: Failed to extract schema for "chat": TypeError: Cannot read properties of undefined (reading 'flags') #909

Open
benji56 opened this issue Feb 28, 2025 · 2 comments

Comments

@benji56
Copy link

benji56 commented Feb 28, 2025

what could cause this error?

"@langchain/community": "^0.3.33",
"@langchain/core": "^0.3.41",
"@langchain/langgraph": "^0.2.49",
"@langchain/openai": "^0.4.4",

info: ▪ <-- GET /assistants/eb6db400-e3c8-5d06-a834-015cb89efe69/schemas
Error: Failed to extract schema for "chat": TypeError: Cannot read properties of undefined (reading 'flags')
at getGraphSchema (file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/@langchain/langgraph-api/dist/graph/load.mjs:68:19)
at async file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/@langchain/langgraph-api/dist/api/assistants.mjs:90:25
at async dispatch (file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/hono/dist/compose.js:22:17)
at async logger2 (file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/hono/dist/middleware/logger/index.js:38:5)
at async dispatch (file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/hono/dist/compose.js:22:17)
at async cors2 (file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/hono/dist/middleware/cors/index.js:74:5)
at async dispatch (file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/hono/dist/compose.js:22:17)
at async file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/@langchain/langgraph-api/dist/server.mjs:26:5
at async dispatch (file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/hono/dist/compose.js:22:17)
at async file:///C:/Users/username/AppData/Local/npm-cache/_npx/8b41b8d3955bcda6/node_modules/hono/dist/hono-base.js:195:25
info: ▪ --> GET /assistants/eb6db400-e3c8-5d06-a834-015cb89efe69/schemas 500 2s

@benji56
Copy link
Author

benji56 commented Feb 28, 2025

It was resolved by porting my project to TypeScript.

@benji56 benji56 closed this as completed Feb 28, 2025
@benji56 benji56 reopened this Feb 28, 2025
@benji56
Copy link
Author

benji56 commented Feb 28, 2025

Now that I've spent hours suffering with TypeScript, I'm not willing to torture myself any longer. Can someone explain why this doesn't work with plain JavaScript?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant