-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Unable to do local build of langchainjs project with dev container #5952
Comments
To resolve the issues with
Here is a sample Dockerfile for setting up the dev container: FROM node:18
# Set working directory
WORKDIR /usr/src/app
# Copy package.json and yarn.lock
COPY package.json yarn.lock ./
# Install Yarn 3.4.1
RUN npm install -g [email protected]
# Install dependencies
RUN yarn install
# Copy the rest of the application code
COPY . .
# Build the project
RUN yarn build
# Expose the port the app runs on
EXPOSE 3000
# Command to run the app
CMD ["yarn", "start"] Ensure that the Dockerfile is placed in the root of your project directory and build the Docker image using: docker build -t langchainjs-dev . Then run the container: docker run -it -p 3000:3000 langchainjs-dev Additionally, the
For more detailed instructions on contributing to the LangChain.js project, including setting up a development container, you can refer to the Contribute Code section in the documentation [1][2][3]. |
I've tried the node 18 dev container and it didn't change the output. I also tried updating the yarn version to the latest with |
Hi @deefactorial , I managed to simulate the problem here and got the same results. I believe that this is happening because the requirements for the library node ➜ /workspaces/langchainjs (fix/devcontainer) $ npm ls sharp
npm notice
npm notice New minor version of npm available! 10.5.2 -> 10.8.1
npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.8.1
npm notice Run npm install -g [email protected] to update!
npm notice
[email protected] /workspaces/langchainjs
└─┬ @langchain/[email protected] invalid: "workspace:*" from libs/langchain-anthropic -> ./libs/langchain-community
└─┬ @xenova/[email protected]
└── [email protected] Searching in the library repo, I found this lovell/sharp#3937, indicating that node node ➜ /workspaces/langchainjs (main) $ node -v
v20.2.0 But that is not the cause of this problem. From the documentation of the
And that seems to be the problem. I've updated the devcontainer version so we can have a node > ➤ YN0000: └ Completed in 0s 419ms
➤ YN0000: ┌ Fetch step
➤ YN0000: └ Completed in 1s 5ms
➤ YN0000: ┌ Link step
➤ YN0000: └ Completed in 1s 265ms
➤ YN0000: Done with warnings in 3s 121ms |
Thank you for looking into this @lamoglia - could you make a PR with that? I wonder if we can avoid building community by default... that would solve a fair number of dependency-related isseus I think |
Sure, PR created. |
Checked other resources
Example Code
yarn install
Error Message and Stack Trace (if applicable)
node ➜ /workspaces/langchainjs (main) $ yarn install
➤ YN0000: ┌ Project validation
➤ YN0057: │ core_docs: Resolutions field will be ignored
➤ YN0000: └ Completed
➤ YN0000: ┌ Resolution step
➤ YN0002: │ @algolia/autocomplete-core@npm:1.9.3 doesn't provide @algolia/client-search (pbc410), requested by @algolia/autocomplete-shared
➤ YN0002: │ @algolia/autocomplete-core@npm:1.9.3 doesn't provide algoliasearch (p8ad5b), requested by @algolia/autocomplete-shared
➤ YN0002: │ @algolia/autocomplete-core@npm:1.9.3 doesn't provide search-insights (pfdb70), requested by @algolia/autocomplete-plugin-algolia-insights
➤ YN0002: │ @algolia/autocomplete-plugin-algolia-insights@npm:1.9.3 [e43f4] doesn't provide @algolia/client-search (pdf3b9), requested by @algolia/autocomplete-shared
➤ YN0002: │ @algolia/autocomplete-plugin-algolia-insights@npm:1.9.3 [e43f4] doesn't provide algoliasearch (p0f6bb), requested by @algolia/autocomplete-shared
➤ YN0002: │ @aws-sdk/credential-provider-node@npm:3.583.0 doesn't provide @aws-sdk/client-sts (p51977), requested by @aws-sdk/credential-provider-web-identity
➤ YN0002: │ @aws-sdk/credential-provider-node@npm:3.583.0 doesn't provide @aws-sdk/client-sts (p07936), requested by @aws-sdk/credential-provider-ini
➤ YN0002: │ @aws-sdk/credential-provider-node@npm:3.592.0 doesn't provide @aws-sdk/client-sts (p42e5a), requested by @aws-sdk/credential-provider-web-identity
➤ YN0002: │ @aws-sdk/credential-provider-node@npm:3.592.0 doesn't provide @aws-sdk/client-sts (p82305), requested by @aws-sdk/credential-provider-ini
➤ YN0002: │ @aws-sdk/credential-provider-node@npm:3.600.0 doesn't provide @aws-sdk/client-sts (pfbe48), requested by @aws-sdk/credential-provider-web-identity
➤ YN0002: │ @aws-sdk/credential-provider-node@npm:3.600.0 doesn't provide @aws-sdk/client-sts (p1279e), requested by @aws-sdk/credential-provider-ini
➤ YN0002: │ @aws-sdk/credential-provider-sso@npm:3.583.0 doesn't provide @aws-sdk/client-sso-oidc (p34559), requested by @aws-sdk/token-providers
➤ YN0002: │ @aws-sdk/credential-provider-sso@npm:3.592.0 doesn't provide @aws-sdk/client-sso-oidc (pb5495), requested by @aws-sdk/token-providers
➤ YN0002: │ @aws-sdk/credential-provider-sso@npm:3.598.0 doesn't provide @aws-sdk/client-sso-oidc (p3b6af), requested by @aws-sdk/token-providers
➤ YN0002: │ @docsearch/react@npm:3.5.2 [2501b] doesn't provide @algolia/client-search (pfbb58), requested by @algolia/autocomplete-preset-algolia
➤ YN0002: │ @langchain/community@workspace:libs/langchain-community doesn't provide @babel/runtime (p19e9d), requested by typesense
➤ YN0060: │ @langchain/community@workspace:libs/langchain-community provides @langchain/core (pe2241) with version 0.2.11, which doesn't satisfy what @getzep/zep-cloud requests
➤ YN0060: │ @langchain/community@workspace:libs/langchain-community provides langchain (p2dd11) with version 0.2.3, which doesn't satisfy what @getzep/zep-cloud requests
➤ YN0002: │ @langchain/community@workspace:libs/langchain-community [0319f] doesn't provide @babel/runtime (p9268d), requested by typesense
➤ YN0060: │ @langchain/community@workspace:libs/langchain-community [0319f] provides @langchain/core (p9797d) with version 0.2.11, which doesn't satisfy what @getzep/zep-cloud requests
➤ YN0060: │ @langchain/community@workspace:libs/langchain-community [0319f] provides langchain (p1721c) with version 0.2.3, which doesn't satisfy what @getzep/zep-cloud requests
➤ YN0060: │ @langchain/community@workspace:libs/langchain-community [0319f] provides mongodb (pe3514) with version 5.2.0, which doesn't satisfy what typeorm requests
➤ YN0002: │ @langchain/google-common@npm:0.0.18 doesn't provide zod (p73392), requested by zod-to-json-schema
➤ YN0060: │ @langchain/standard-tests@workspace:libs/langchain-standard-tests provides zod (p117e8) with version 3.22.4, which doesn't satisfy what zod-to-json-schema requests
➤ YN0002: │ core_docs@workspace:docs/core_docs doesn't provide @babel/core (p52994), requested by @babel/eslint-parser
➤ YN0002: │ core_docs@workspace:docs/core_docs doesn't provide typescript (p16606), requested by typedoc
➤ YN0002: │ crlf-normalize@npm:1.0.18 doesn't provide ts-toolbelt (pd32c8), requested by ts-type
➤ YN0002: │ examples@workspace:examples doesn't provide @babel/runtime (pd2afb), requested by typesense
➤ YN0060: │ examples@workspace:examples provides @langchain/core (pc67be) with version 0.2.11, which doesn't satisfy what @getzep/zep-cloud requests
➤ YN0002: │ examples@workspace:examples doesn't provide @tensorflow/tfjs-core (pe7130), requested by @tensorflow/tfjs-backend-cpu
➤ YN0060: │ examples@workspace:examples provides @typescript-eslint/eslint-plugin (pd11cb) with version 5.54.1, which doesn't satisfy what eslint-plugin-unused-imports requests
➤ YN0060: │ examples@workspace:examples provides langchain (pf2ed0) with version 0.2.8, which doesn't satisfy what @getzep/zep-cloud requests
➤ YN0060: │ examples@workspace:examples provides mongodb (p2c5ac) with version 6.3.0, which doesn't satisfy what typeorm requests
➤ YN0060: │ langchain@workspace:langchain [e0604] provides mongodb (pa6132) with version 5.2.0, which doesn't satisfy what typeorm requests
➤ YN0060: │ langchain@workspace:langchain [fadf1] provides mongodb (p882b8) with version 5.2.0, which doesn't satisfy what typeorm requests
➤ YN0002: │ weaviate-ts-client@npm:1.4.0 doesn't provide graphql (p06027), requested by graphql-request
➤ YN0002: │ weaviate-ts-client@npm:2.0.0 doesn't provide graphql (p6c7c6), requested by graphql-request
➤ YN0000: │ Some peer dependencies are incorrectly met; run yarn explain peer-requirements for details, where is the six-letter p-prefixed code
➤ YN0000: └ Completed in 0s 425ms
➤ YN0000: ┌ Fetch step
➤ YN0013: │ @types/crypto-js@npm:4.2.2 can't be found in the cache and will be fetched from the remote registry
➤ YN0013: │ @types/d3-dsv@npm:2.0.3 can't be found in the cache and will be fetched from the remote registry
➤ YN0013: │ @types/decamelize@npm:1.2.0 can't be found in the cache and will be fetched from the remote registry
➤ YN0013: │ @types/dns-packet@npm:5.6.5 can't be found in the cache and will be fetched from the remote registry
➤ YN0013: │ @types/dompurify@npm:3.0.5 can't be found in the cache and will be fetched from the remote registry
➤ YN0000: ⠋ ============================----------------------------------------------------
Killed
Description
yarn install
script and it terminates withKilled
response pre-maturely. I expect it to install all dependencies correctly.yarn build
but I get error:System Info
node ➜ /workspaces/langchainjs (main) $ yarn info langchain Usage Error: No package matched your request $ yarn info [-A,--all] [-R,--recursive] [-X,--extra #0] [--cache] [--dependents] [--manifest] [--name-only] [--virtuals] [--json] ...
Platform: mac
node -v: v20.2.0
yarn --version: 3.4.1
The text was updated successfully, but these errors were encountered: