[Snyk] Security upgrade langchain from 0.3.31 to 1.0.1#891
[Snyk] Security upgrade langchain from 0.3.31 to 1.0.1#891graymalkin77 wants to merge 1 commit intomasterfrom
Conversation
…rris-jokes/package-lock.json to reduce vulnerabilities The following vulnerabilities are fixed with an upgrade: - https://snyk.io/vuln/SNYK-JS-LANGSMITH-15969264
|
The upgrade from Key Breaking Changes:
Source: LangChain v1 Migration Guide, Release Notes Recommendation: This upgrade requires a significant refactoring effort. Developers must carefully follow the official migration guide to update package imports, agent creation logic, and method calls to align with the new v1.0 API. This should be handled in a separate, dedicated effort before merging.
|
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
There was a problem hiding this comment.
Pull request overview
This PR is an automated Snyk security upgrade for the extensions/chuck-norris-jokes extension, updating langchain to remediate a reported vulnerability in the dependency tree.
Changes:
- Bump
langchaindependency from0.3.31to1.0.1inextensions/chuck-norris-jokes/package.json. - Update
extensions/chuck-norris-jokes/package-lock.jsonto reflect the new dependency graph (including new transitive packages and versions).
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| extensions/chuck-norris-jokes/package.json | Updates the direct langchain dependency version. |
| extensions/chuck-norris-jokes/package-lock.json | Updates the lockfile for the new langchain version and its transitive dependencies. |
Files not reviewed (1)
- extensions/chuck-norris-jokes/package-lock.json: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "html-to-text": "9.0.5", | ||
| "jsdom": "24.1.3", | ||
| "langchain": "0.3.31" | ||
| "langchain": "^1.0.1" |
There was a problem hiding this comment.
In package-lock.json, the root package dependency spec for langchain is now "^1.0.1", but package.json pins "1.0.1". This mismatch typically causes npm ci / npm install to fail with “package-lock.json is not up to date with package.json”. Regenerate the lockfile (or edit it) so the spec exactly matches package.json.
| "langchain": "^1.0.1" | |
| "langchain": "1.0.1" |
| "html-to-text": "9.0.5", | ||
| "jsdom": "24.1.3", | ||
| "langchain": "0.3.31" | ||
| "langchain": "1.0.1" | ||
| }, |
There was a problem hiding this comment.
Upgrading to [email protected] introduces transitive dependencies that declare engines.node >=20 (see package-lock entries for langchain/@langchain/core). This extension’s package.json doesn’t declare a Node engine, and the codebase doesn’t appear to import langchain anywhere under this extension. Either (1) confirm and document/declare the required Node version for this package, or (2) remove langchain from dependencies if it’s not actually used, to avoid forcing Node>=20 unnecessarily.
Snyk has created this PR to fix 1 vulnerabilities in the npm dependencies of this project.
Snyk changed the following file(s):
extensions/chuck-norris-jokes/package.jsonextensions/chuck-norris-jokes/package-lock.jsonVulnerabilities that will be fixed with an upgrade:
SNYK-JS-LANGSMITH-15969264
Breaking Change Risk
Important
Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.
For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic
Learn how to fix vulnerabilities with free interactive lessons:
🦉 Prototype Pollution