Skip to content
This repository was archived by the owner on Sep 7, 2026. It is now read-only.

Address dependency security advisories - #373

Open
dannyhw wants to merge 6 commits into
mainfrom
dannyhw/fix-dependabot-alerts
Open

dannyhw wants to merge 6 commits into
mainfrom
dannyhw/fix-dependabot-alerts

Conversation

@dannyhw

@dannyhw dannyhw commented Jul 27, 2026

Copy link
Copy Markdown
Member

What changed

  • update direct dependencies and shared catalogs to patched releases, including Codecov, MCP Inspector/SDK, Vitest, Vite, Valibot, Storybook, ESLint, Vercel CLI, Next.js, srvx, and agent-eval
  • merge the latest main changes and preserve the follow-up template pin and CodeRabbit review fixes already pushed to this branch
  • refresh all independent pnpm lockfiles, including patched brace-expansion, fast-uri, hono, and @hono/node-server releases
  • update the existing agent-eval compatibility patch from 1.2.0 to 1.4.0 and port main's NO_COLOR behavior to it
  • link the self-host example to the workspace MCP package so it uses the updated Valibot dependency normally
  • add the required @storybook/mcp patch changeset
  • retain zero pnpm overrides

Why

Dependabot and pnpm audit reported vulnerable direct and transitive dependencies across the repository's independent lockfiles. This updates owning packages wherever releases are available and uses compatible lockfile bumps for patched transitive releases instead of forcing versions through overrides.

Eight of the repository's nine independent lockfiles now audit clean, including the root, internal Storybook, eval, self-host example, and every published package graph.

Impact

There are no application behavior changes intended. The notable dependency upgrades are covered by the repository's full build, typecheck, lint, package, Storybook, and test suites. The self-host MCP endpoint and evaluation tooling also received direct smoke validation.

Validation

  • pnpm run format
  • pnpm run check — 14/14 tasks, 54 test files, 757 tests
  • pnpm audit across all nine independent lockfiles
  • agent-eval playground production build on Next.js 16.3.0
  • agent-eval route-shim validation — all 9 upstream routes match
  • internal Storybook production build and MCP endpoint E2E tests
  • Vercel CLI, agent-eval CLI, MCP Inspector CLI, and self-host MCP initialization smoke checks

Not resolved

  • agent-eval/pnpm-lock.yaml retains 35 findings: 6 low, 16 moderate, 12 high, and 1 critical. They remain visible rather than being masked with overrides and are isolated from the published MCP package graphs.
  • Most are pinned through Vercel CLI 57.0.0 (undici, tar, minimatch, ajv, smol-toml, path-to-regexp, js-yaml, and @tootallnate/once). The current Vercel CLI release metadata still pins the affected dependency lines, so resolving them needs upstream Vercel package updates.
  • The rest are through @vercel/agent-eval 1.4.0 and its AI SDK/docker dependencies, plus one low-severity esbuild finding selected through Vite's optional tsx peer. There is no newer agent-eval release, and resolving the Vite path without steering the transitive version would require a broader Vite 8 upgrade.

Summary by CodeRabbit

  • Updates
    • Refreshed development and testing tools across projects and templates, including Vite, Vitest, Storybook, ESLint, and related packages.
    • Updated evaluation tooling and related dependencies for improved consistency.
  • Reliability & Behavior
    • Improved evaluation/runtime reliability with safer playground execution, more consistent transcript handling, and improved captured-output cleanliness.
    • Enhanced classifier enablement and selection to support an additional credential source.
    • Fixed Docker-based workflow output issues where large logs could become corrupted.
  • Integration
    • Updated self-hosted MCP setup with newer server tooling and workspace-linked Storybook integration.

@netlify

netlify Bot commented Jul 27, 2026

Copy link
Copy Markdown

Deploy Preview for storybook-mcp-self-host-example ready!

Name Link
🔨 Latest commit 7155bd9
🔍 Latest deploy log https://app.netlify.com/projects/storybook-mcp-self-host-example/deploys/6a7332425f78b300080b6134
😎 Deploy Preview https://deploy-preview-373--storybook-mcp-self-host-example.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@changeset-bot

changeset-bot Bot commented Jul 27, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 7155bd9

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@storybook/mcp Patch
@storybook/addon-mcp Patch
@storybook/mcp-self-host Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new

pkg-pr-new Bot commented Jul 27, 2026

Copy link
Copy Markdown
npx https://pkg.pr.new/storybookjs/mcp/@storybook/addon-mcp@373
npx https://pkg.pr.new/storybookjs/mcp/@storybook/mcp@373

commit: 7155bd9

@codecov

codecov Bot commented Jul 27, 2026

Copy link
Copy Markdown

Bundle Report

Bundle size has no change ✅

@codecov

codecov Bot commented Jul 27, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.66%. Comparing base (95bfb45) to head (d7cf79b).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #373   +/-   ##
=======================================
  Coverage   79.66%   79.66%           
=======================================
  Files          50       50           
  Lines        2095     2095           
  Branches      624      624           
=======================================
  Hits         1669     1669           
  Misses        220      220           
  Partials      206      206           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

@dannyhw
dannyhw marked this pull request as ready for review July 27, 2026 17:12
@coderabbitai

coderabbitai Bot commented Jul 27, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

Walkthrough

The PR updates workspace dependencies and catalogs across agent evaluation, templates, MCP packages, and development tooling. It also updates the @vercel/agent-eval patch for playground execution, classifier routing, transcript handling, captured output, and Docker streams.

Changes

Dependency and agent-eval updates

Layer / File(s) Summary
Agent-eval version wiring
agent-eval/package.json, pnpm-workspace.yaml, agent-eval/templates/...
Agent-eval, Vercel, Next, and related patch references are upgraded. Evaluation templates use the updated agent-eval and testing versions.
Agent-eval runtime patch
agent-eval/patches/...
The patch pins playground versions, adds Anthropic classifier routing, updates Codex transcript selection, disables captured command colors, and uses Docker stream demultiplexing.
Workspace tooling alignment
pnpm-workspace.yaml, package.json, eval/package.json, agent-eval/evals/..., agent-eval/templates/...
Workspace catalogs and development manifests update Storybook, Vitest, Vite, Valibot, ESLint, coverage, and related tooling.
MCP dependency wiring
apps/self-host-mcp/package.json, packages/mcp/package.json
srvx is upgraded, and self-hosted MCP uses the workspace @storybook/mcp package.
Dependency release metadata
.changeset/secure-dependencies-refresh.md
A patch changeset records the @storybook/mcp dependency update.

Possibly related PRs


Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
agent-eval/patches/@vercel__agent-eval@1.4.0.patch (1)

48-53: 🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

Use the selected transcript source for observed-model extraction.

transcript prefers stdoutTranscript, but observedModel prefers sessionTranscript. When both exist, the stored transcript and observed model can describe different runs. Use the same stdout-first source, ideally transcript itself.

Proposed fix
-  const observedModel = extractObservedModelFromCodexSession(sessionTranscript ?? stdoutTranscript) ?? null;
+  const observedModel = extractObservedModelFromCodexSession(stdoutTranscript ?? sessionTranscript) ?? null;
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@agent-eval/patches/`@vercel__agent-eval@1.4.0.patch around lines 48 - 53,
Update observed-model extraction to use the already selected stdout-first
transcript source in transcript, rather than independently preferring
sessionTranscript. Pass transcript to extractObservedModelFromCodexSession so
the stored transcript and observed model always describe the same run.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@agent-eval/patches/`@vercel__agent-eval@1.4.0.patch:
- Around line 48-53: Update observed-model extraction to use the already
selected stdout-first transcript source in transcript, rather than independently
preferring sessionTranscript. Pass transcript to
extractObservedModelFromCodexSession so the stored transcript and observed model
always describe the same run.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: d2c7021c-a703-41b0-883a-e16860ef7c01

📥 Commits

Reviewing files that changed from the base of the PR and between e4f90aa and 1c24f98.

⛔ Files ignored due to path filters (9)
  • agent-eval/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • apps/internal-storybook/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • apps/self-host-mcp/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • eval/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • packages/addon-mcp/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • packages/claude-plugin/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • packages/codex-plugin/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • packages/mcp/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (13)
  • agent-eval/evals/812-first-story-empty-project/package.json
  • agent-eval/package.json
  • agent-eval/patches/@vercel__agent-eval@1.4.0.patch
  • agent-eval/templates/monorepo/package.json
  • agent-eval/templates/monorepo/packages/app/package.json
  • agent-eval/templates/monorepo/packages/ui/package.json
  • agent-eval/templates/reshaped-storybook/package.json
  • agent-eval/templates/vite-app/package.json
  • apps/self-host-mcp/package.json
  • eval/package.json
  • package.json
  • packages/mcp/package.json
  • pnpm-workspace.yaml

@ndelangen ndelangen self-assigned this Jul 29, 2026
@ndelangen
ndelangen force-pushed the dannyhw/fix-dependabot-alerts branch from 1c24f98 to 9d4ef00 Compare July 29, 2026 10:03

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
agent-eval/patches/@vercel__agent-eval@1.4.0.patch (2)

119-120: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Document the existing OIDC fallback.

classifyWithAI() still supports VERCEL_OIDC_TOKEN through the gateway branch, but these JSDoc strings mention only Anthropic and AI_GATEWAY_API_KEY. Include VERCEL_OIDC_TOKEN for consistency.

Also applies to: 163-163

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@agent-eval/patches/`@vercel__agent-eval@1.4.0.patch around lines 119 - 120,
Update the JSDoc for classifyWithAI() and its corresponding second documentation
occurrence to mention VERCEL_OIDC_TOKEN as an accepted credential for the Vercel
AI Gateway path, alongside ANTHROPIC_API_KEY and AI_GATEWAY_API_KEY.

68-69: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Set NO_COLOR after merging the caller environment.

{ NO_COLOR: '1', ...env } allows env.NO_COLOR to override the forced value, so captured output may still contain ANSI codes. Merge env first and assign NO_COLOR last.

Proposed fix
-        const outputEnv = { NO_COLOR: '1', ...env };
+        const outputEnv = { ...env, NO_COLOR: '1' };
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@agent-eval/patches/`@vercel__agent-eval@1.4.0.patch around lines 68 - 69,
Update the outputEnv construction in the test execution flow to merge env first
and assign NO_COLOR last, ensuring caller-provided values cannot override the
forced "1" setting before passing it to sandbox.runCommand.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@agent-eval/templates/vite-app/package.json`:
- Around line 25-26: Update the `@vercel/agent-eval` dependency pin from 1.2.0 to
1.4.0 in the vite-app package manifest and every other template manifest
containing the stale pin, ensuring all generated projects use version 1.4.0.

---

Outside diff comments:
In `@agent-eval/patches/`@vercel__agent-eval@1.4.0.patch:
- Around line 119-120: Update the JSDoc for classifyWithAI() and its
corresponding second documentation occurrence to mention VERCEL_OIDC_TOKEN as an
accepted credential for the Vercel AI Gateway path, alongside ANTHROPIC_API_KEY
and AI_GATEWAY_API_KEY.
- Around line 68-69: Update the outputEnv construction in the test execution
flow to merge env first and assign NO_COLOR last, ensuring caller-provided
values cannot override the forced "1" setting before passing it to
sandbox.runCommand.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 8981fb39-5597-486b-ac0e-da413b886217

📥 Commits

Reviewing files that changed from the base of the PR and between 1c24f98 and 9d4ef00.

⛔ Files ignored due to path filters (9)
  • agent-eval/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • apps/internal-storybook/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • apps/self-host-mcp/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • eval/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • packages/addon-mcp/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • packages/claude-plugin/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • packages/codex-plugin/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • packages/mcp/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (13)
  • agent-eval/evals/812-first-story-empty-project/package.json
  • agent-eval/package.json
  • agent-eval/patches/@vercel__agent-eval@1.4.0.patch
  • agent-eval/templates/monorepo/package.json
  • agent-eval/templates/monorepo/packages/app/package.json
  • agent-eval/templates/monorepo/packages/ui/package.json
  • agent-eval/templates/reshaped-storybook/package.json
  • agent-eval/templates/vite-app/package.json
  • apps/self-host-mcp/package.json
  • eval/package.json
  • package.json
  • packages/mcp/package.json
  • pnpm-workspace.yaml
🚧 Files skipped from review as they are similar to previous changes (10)
  • agent-eval/templates/monorepo/packages/app/package.json
  • packages/mcp/package.json
  • apps/self-host-mcp/package.json
  • agent-eval/templates/monorepo/packages/ui/package.json
  • agent-eval/templates/reshaped-storybook/package.json
  • package.json
  • agent-eval/templates/monorepo/package.json
  • pnpm-workspace.yaml
  • eval/package.json
  • agent-eval/package.json

Comment thread agent-eval/templates/vite-app/package.json
Generated eval projects were still referencing @vercel/agent-eval 1.2.0
while the workspace and patch migrated to 1.4.0.

Co-authored-by: Cursor <cursoragent@cursor.com>
@ndelangen

Copy link
Copy Markdown
Member

@shilman @dannyhw is this good to merge as-is?

Ensure NO_COLOR cannot be overridden by caller env, and document
VERCEL_OIDC_TOKEN alongside the other classifier credential options.

Co-authored-by: Cursor <cursoragent@cursor.com>
@dannyhw

dannyhw commented Jul 29, 2026

Copy link
Copy Markdown
Member Author

I think so, i could do a quick check. My first time contributing on the repo so i might miss something im not familiar with tho

@dannyhw
dannyhw marked this pull request as draft August 5, 2026 12:55
@dannyhw
dannyhw marked this pull request as ready for review August 5, 2026 12:57
@ndelangen

Copy link
Copy Markdown
Member

I think you may want to hold off spending any more time on this repo @dannyhw
It's getting moves/overhauled.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants