danny-avila / LibreChat

Enhanced ChatGPT Clone: Features Anthropic, OpenAI, Assistants API, Azure, Groq, GPT-4o, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, langchain, DALL-E-3, ChatGPT Plugins, OpenAI Functions, Secure Multi-User System, Presets, completely open-source for self-hosting. Actively in public development.
https://librechat.ai/
MIT License
17.2k stars 2.87k forks source link

[Bug]: LibreChat exit code 1 after docker-compose up #735

Closed nikhase closed 1 year ago

nikhase commented 1 year ago

What happened?

I am using v0.5.6.

2 weeks ago it worked, then I did the mistake to rebuild the containers.

Is it maybe related to https://github.com/langchain-ai/langchain/pull/7388 , renaming of langchainplus-sdk to langsmith?

Steps to Reproduce

  1. docker-compose build --no-cache && docker-compose up --force-recreate

What browsers are you seeing the problem on?

No response

Relevant log output

LibreChat         | > LibreChat@0.5.6 backend
LibreChat         | > cross-env NODE_ENV=production node api/server/index.js
LibreChat         | 
LibreChat         | 
LibreChat         | Clearing sync timeouts before exiting...
LibreChat         | node:internal/modules/cjs/loader:1093
LibreChat         |   throw err;
LibreChat         |   ^
LibreChat         | 
LibreChat         | Error: Cannot find module 'langchainplus-sdk'
LibreChat         | Require stack:
LibreChat         | - /app/api/node_modules/langchain/dist/callbacks/handlers/tracer_langchain.cjs
LibreChat         | - /app/api/node_modules/langchain/dist/callbacks/handlers/initialize.cjs
LibreChat         | - /app/api/node_modules/langchain/dist/callbacks/manager.cjs
LibreChat         | - /app/api/node_modules/langchain/dist/chat_models/base.cjs
LibreChat         | - /app/api/node_modules/langchain/dist/chat_models/openai.cjs
LibreChat         | - /app/api/node_modules/langchain/chat_models/openai.cjs
LibreChat         | - /app/api/app/clients/BaseClient.js
LibreChat         | - /app/api/app/clients/ChatGPTClient.js
LibreChat         | - /app/api/app/clients/index.js
LibreChat         | - /app/api/app/index.js
LibreChat         | - /app/api/server/routes/ask/openAI.js
LibreChat         | - /app/api/server/routes/ask/index.js
LibreChat         | - /app/api/server/routes/index.js
LibreChat         | - /app/api/server/index.js
LibreChat         |     at Module._resolveFilename (node:internal/modules/cjs/loader:1090:15)
LibreChat         |     at Module._load (node:internal/modules/cjs/loader:934:27)
LibreChat         |     at Module.require (node:internal/modules/cjs/loader:1157:19)
LibreChat         |     at require (node:internal/modules/helpers:119:18)
LibreChat         |     at Object.<anonymous> (/app/api/node_modules/langchain/dist/callbacks/handlers/tracer_langchain.cjs:4:29)
LibreChat         |     at Module._compile (node:internal/modules/cjs/loader:1275:14)
LibreChat         |     at Module._extensions..js (node:internal/modules/cjs/loader:1329:10)
LibreChat         |     at Module.load (node:internal/modules/cjs/loader:1133:32)
LibreChat         |     at Module._load (node:internal/modules/cjs/loader:972:12)
LibreChat         |     at Module.require (node:internal/modules/cjs/loader:1157:19) {
LibreChat         |   code: 'MODULE_NOT_FOUND',
LibreChat         |   requireStack: [
LibreChat         |     '/app/api/node_modules/langchain/dist/callbacks/handlers/tracer_langchain.cjs',
LibreChat         |     '/app/api/node_modules/langchain/dist/callbacks/handlers/initialize.cjs',
LibreChat         |     '/app/api/node_modules/langchain/dist/callbacks/manager.cjs',
LibreChat         |     '/app/api/node_modules/langchain/dist/chat_models/base.cjs',
LibreChat         |     '/app/api/node_modules/langchain/dist/chat_models/openai.cjs',
LibreChat         |     '/app/api/node_modules/langchain/chat_models/openai.cjs',
LibreChat         |     '/app/api/app/clients/BaseClient.js',
LibreChat         |     '/app/api/app/clients/ChatGPTClient.js',
LibreChat         |     '/app/api/app/clients/index.js',
LibreChat         |     '/app/api/app/index.js',
LibreChat         |     '/app/api/server/routes/ask/openAI.js',
LibreChat         |     '/app/api/server/routes/ask/index.js',
LibreChat         |     '/app/api/server/routes/index.js',
LibreChat         |     '/app/api/server/index.js'
LibreChat         |   ]
LibreChat         | }
LibreChat         | 
LibreChat         | Node.js v19.9.0
LibreChat         | 
LibreChat exited with code 1

Screenshots

No response

Code of Conduct

fuegovic commented 1 year ago

you can always try the new update command, this should clean up your container at the same time:

npm run update:docker

If the update command doen't work, another fix for that has been documented here: https://github.com/danny-avila/LibreChat/blob/main/docs/general_info/breaking_changes.md#v055

nikhase commented 1 year ago

Thank you very much for your fast response! It works now! I am sorry that I missed that breaking changes docs.

Best wishes! And thanks for this great effort with LibreChat!