-
Notifications
You must be signed in to change notification settings - Fork 1
[Snyk] Fix for 3 vulnerabilities #11559
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
base: master
Are you sure you want to change the base?
Conversation
…nerabilities The following vulnerabilities are fixed with an upgrade: - https://snyk.io/vuln/SNYK-JS-TAR-15032660 - https://snyk.io/vuln/SNYK-JS-TAR-15127355 - https://snyk.io/vuln/SNYK-JS-ESLINT-15102420
Review or Edit in CodeSandboxOpen the branch in Web Editor • VS Code • Insiders |
⛔ Snyk checks have failed. 1 issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
Summary of ChangesHello @q1blue, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request is an automated security fix initiated by Snyk to upgrade several core Backstage dependencies within the Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
|
Warning Review the following alerts detected in dependencies. According to your organization's Security Policy, it is recommended to resolve "Warn" alerts. Learn more about Socket for GitHub.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request, automatically generated by Snyk, aims to fix security vulnerabilities by pinning several @backstage dependencies to specific versions. However, this approach is problematic for a monorepo using Yarn workspaces, as it replaces workspace:^ with fixed versions. This breaks the local development workflow, as changes in local workspace packages will no longer be reflected. The PR also notes that yarn.lock was not updated, further indicating an incomplete and potentially damaging change. I've recommended reverting these changes and performing a proper workspace-wide dependency update instead.
| "@backstage/backend-common": "0.24.1", | ||
| "@backstage/backend-plugin-api": "workspace:^", | ||
| "@backstage/backend-tasks": "workspace:^", | ||
| "@backstage/catalog-client": "workspace:^", | ||
| "@backstage/catalog-model": "workspace:^", | ||
| "@backstage/catalog-model": "0.1.1", | ||
| "@backstage/config": "workspace:^", | ||
| "@backstage/errors": "workspace:^", | ||
| "@backstage/integration": "workspace:^", | ||
| "@backstage/plugin-catalog-backend": "workspace:^", | ||
| "@backstage/plugin-catalog-common": "workspace:^", | ||
| "@backstage/plugin-catalog-backend": "2.0.0", | ||
| "@backstage/plugin-catalog-common": "0.1.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pinning Backstage dependencies to specific versions breaks the yarn workspace linking in this monorepo. This means local changes in these dependencies (e.g., @backstage/backend-common) will not be picked up by this package during development, which can lead to inconsistencies and hard-to-debug issues.
This change was likely automated by Snyk to fix vulnerabilities, but it doesn't correctly handle monorepo setups. This is also indicated by the PR note: Failed to update the yarn.lock, please update manually before merging.
It's recommended to revert these changes to use workspace:^ and instead perform a proper workspace-wide dependency upgrade to resolve the vulnerabilities.
"@backstage/backend-common": "workspace:^",
"@backstage/backend-plugin-api": "workspace:^",
"@backstage/backend-tasks": "workspace:^",
"@backstage/catalog-client": "workspace:^",
"@backstage/catalog-model": "workspace:^",
"@backstage/config": "workspace:^",
"@backstage/errors": "workspace:^",
"@backstage/integration": "workspace:^",
"@backstage/plugin-catalog-backend": "workspace:^",
"@backstage/plugin-catalog-common": "workspace:^"
WalkthroughThis PR updates the dependency management strategy for the catalog-backend-module-github plugin by replacing workspace protocol references with explicit version numbers for four Backstage packages. The changes transition from monorepo workspace dependencies to pinned external package versions, specifying @backstage/backend-common at 0.24.1, @backstage/catalog-model at 0.1.1, @backstage/plugin-catalog-backend at 2.0.0, and @backstage/plugin-catalog-common at 0.1.0. This modification likely supports package publishing workflows or establishes more controlled dependency versioning for the plugin. Changes
Sequence DiagramThis diagram shows the interactions between components: sequenceDiagram
participant Dev as Developer
participant PM as Package Manager
participant Registry as NPM Registry
participant Module as catalog-backend-module-github
Note over Dev,Registry: Dependency Resolution Change
Dev->>PM: Update package.json dependencies
Note right of Dev: Change workspace:^ to fixed versions:<br/>- backend-common: 0.24.1<br/>- catalog-model: 0.1.1<br/>- plugin-catalog-backend: 2.0.0<br/>- plugin-catalog-common: 0.1.0
Dev->>PM: Run install command
alt Fixed Version Dependencies
PM->>Registry: Fetch exact version 0.24.1 of backend-common
Registry-->>PM: Return version 0.24.1
PM->>Registry: Fetch exact version 0.1.1 of catalog-model
Registry-->>PM: Return version 0.1.1
PM->>Registry: Fetch exact version 2.0.0 of plugin-catalog-backend
Registry-->>PM: Return version 2.0.0
PM->>Registry: Fetch exact version 0.1.0 of plugin-catalog-common
Registry-->>PM: Return version 0.1.0
else Workspace Dependencies (Previous)
PM->>PM: Resolve from local workspace
Note right of PM: Uses local versions<br/>from monorepo
end
PM->>Module: Install resolved dependencies
Module-->>Dev: Dependencies installed with fixed versions
Note over Dev,Module: Build reproducibility improved<br/>with pinned versions
Note for WindsurfPlease change the default marketplace provider to the following in the windsurf settings:Marketplace Extension Gallery Service URL: https://marketplace.visualstudio.com/_apis/public/gallery Marketplace Gallery Item URL: https://marketplace.visualstudio.com/items Entelligence.ai can learn from your feedback. Simply add 👍 / 👎 emojis to teach it your preferences. More shortcuts belowEmoji Descriptions:
Interact with the Bot:
Also you can trigger various commands with the bot by doing The current supported commands are
More commands to be added soon. |
Snyk has created this PR to fix 3 vulnerabilities in the yarn dependencies of this project.
Snyk changed the following file(s):
plugins/catalog-backend-module-github/package.jsonNote for zero-installs users
If you are using the Yarn feature zero-installs that was introduced in Yarn V2, note that this PR does not update the
.yarn/cache/directory meaning this code cannot be pulled and immediately developed on as one would expect for a zero-install project - you will need to runyarnto update the contents of the./yarn/cachedirectory.If you are not using zero-install you can ignore this as your flow should likely be unchanged.
Vulnerabilities that will be fixed with an upgrade:
SNYK-JS-TAR-15032660
SNYK-JS-TAR-15127355
SNYK-JS-ESLINT-15102420
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:
🦉 Directory Traversal
EntelligenceAI PR Summary
This PR transitions the catalog-backend-module-github plugin from workspace protocol dependencies to pinned external package versions.
@backstage/backend-commondependency to version 0.24.1@backstage/catalog-modeldependency to version 0.1.1@backstage/plugin-catalog-backenddependency to version 2.0.0@backstage/plugin-catalog-commondependency to version 0.1.0plugins/catalog-backend-module-github/package.json