Skip to content

Fix Storybook build: remove invalid positional argument in build-storybook script#3004

Merged
llastflowers merged 6 commits intodependabot/npm_and_yarn/docs/multi-15a9fc0651from
copilot/fix-github-actions-workflow-another-one
Mar 12, 2026
Merged

Fix Storybook build: remove invalid positional argument in build-storybook script#3004
llastflowers merged 6 commits intodependabot/npm_and_yarn/docs/multi-15a9fc0651from
copilot/fix-github-actions-workflow-another-one

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 12, 2026

Storybook 10 dropped support for positional arguments in the build command. The docs/script/build-storybook script was passing public/static as a positional arg, causing the Deploy Preview CI job to fail with:

error: too many arguments for 'build'. Expected 0 arguments but got 1.

What are you trying to accomplish?

Fix the failing "Deploy preview / Build" GitHub Actions job caused by an incompatible storybook build invocation.

What approach did you choose and why?

Remove the public/static positional argument from the storybook build invocation in docs/script/build-storybook. The static directory is already declared in .storybook/main.js via staticDirs: ['../stories/static'] — the CLI argument was redundant and is no longer accepted in Storybook 10.

-npx storybook build -o public/storybook public/static
+npx storybook build -o public/storybook

What should reviewers focus on?

Confirm that the static assets previously served from public/static are correctly covered by the staticDirs config in .storybook/main.js.

Can these changes ship as is?

  • Yes, this PR does not depend on additional changes. 🚢
Original prompt

Fix the failing GitHub Actions workflow Deploy preview / Build
Analyze the workflow logs, identify the root cause of the failure, and implement a fix.
Job ID: 66657338185
Job URL: https://github.com/primer/css/actions/runs/22929439294/job/66657338185


💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.

dependabot Bot and others added 2 commits March 10, 2026 23:46
Removes [tar](https://github.com/isaacs/node-tar). It's no longer used after updating ancestor dependency [storybook](https://github.com/storybookjs/storybook/tree/HEAD/code/core). These dependencies need to be updated together.


Removes `tar`

Updates `storybook` from 7.6.21 to 10.2.17
- [Release notes](https://github.com/storybookjs/storybook/releases)
- [Changelog](https://github.com/storybookjs/storybook/blob/next/CHANGELOG.md)
- [Commits](https://github.com/storybookjs/storybook/commits/v10.2.17/code/core)

---
updated-dependencies:
- dependency-name: tar
  dependency-version: 
  dependency-type: indirect
- dependency-name: storybook
  dependency-version: 10.2.17
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Mar 12, 2026

⚠️ No Changeset found

Latest commit: 46f372f

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

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

Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>
Copilot AI changed the title [WIP] [66657338185] Fix failing GitHub Actions workflow Fix Storybook build: remove invalid positional argument in build-storybook script Mar 12, 2026
Copilot AI requested a review from llastflowers March 12, 2026 17:22
@dependabot dependabot Bot force-pushed the dependabot/npm_and_yarn/docs/multi-15a9fc0651 branch 2 times, most recently from 680b28d to 784dce7 Compare March 12, 2026 18:24
Copilot AI and others added 2 commits March 12, 2026 13:18
* Initial plan

* Fix ESM compatibility: replace require('sass') with ESM import in main.js

Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>

* Fix Storybook 10 build: complete v7→v10 migration (#3007)

* Initial plan

* Initial plan for fixing storybook build failures

Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>

* Fix Storybook 10 build: update packages, add SCSS/Babel/docs support, fix compat shims

Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>

* Address code review: remove unused assert dep, rename config var, clean up shim script

Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>

* Fix docs npm install failure due to storybook peer dependency conflicts (#3008)

* Initial plan

* fix: resolve storybook peer dependency conflicts in docs install

- Update @geometricpanda/storybook-addon-badges to ^2.0.5 which supports @storybook/blocks@^8.3.0 (v2.0.0 only supported ^7.0.0)
- Add docs/.npmrc with legacy-peer-deps=true to handle the intentional mixed storybook 8/10 package setup used by shims and webpack aliases

Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>
…ilot/fix-github-actions-workflow-another-one
…t found (#3009)

* Initial plan

* fix: regenerate docs/package-lock.json to fix storybook binary not found

Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: llastflowers <55068883+llastflowers@users.noreply.github.com>
@llastflowers llastflowers marked this pull request as ready for review March 12, 2026 21:20
@llastflowers llastflowers requested review from a team as code owners March 12, 2026 21:20
@llastflowers llastflowers requested a review from hectahertz March 12, 2026 21:20
@llastflowers llastflowers merged commit d12dd66 into dependabot/npm_and_yarn/docs/multi-15a9fc0651 Mar 12, 2026
14 checks passed
@llastflowers llastflowers deleted the copilot/fix-github-actions-workflow-another-one branch March 12, 2026 21:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants