storybook: Blocker | Storybook local server failing - 5.3.11

Local server with npm run storybook is failing. Tested with 5.3.11. Below are my package json dependencies and error.

Note: Works with forced v5.3.10.

package.json

“devDependencies”: { “@babel/core”: “^7.8.4”, “@babel/preset-env”: “^7.8.4”, “@babel/preset-react”: “^7.8.3”, “@emotion/babel-preset-css-prop”: “^10.0.27”, “@emotion/core”: “^10.0.27”, “@emotion/styled”: “^10.0.27”, “@storybook/addon-a11y”: “^5.3.11”, “@storybook/addon-actions”: “^5.3.11”, “@storybook/addon-backgrounds”: “^5.3.11”, “@storybook/addon-docs”: “^5.3.11”, “@storybook/addon-info”: “^5.3.11”, “@storybook/addon-knobs”: “^5.3.11”, “@storybook/addon-storysource”: “^5.3.11”, “@storybook/react”: “^5.3.11”, “@storybook/source-loader”: “^5.3.11”, “@testing-library/react-hooks”: “^3.2.1”, “babel-eslint”: “^10.0.3”, “babel-jest”: “^25.1.0”, “babel-loader”: “^8.0.6”, “classnames”: “^2.2.6”, “css-loader”: “^3.4.2”, “emotion”: “^10.0.27”, “emotion-theming”: “^10.0.27”, “enzyme”: “^3.11.0”, “enzyme-adapter-react-16”: “^1.15.2”, “eslint”: “^6.8.0”, “eslint-config-airbnb”: “18.0.1”, “eslint-import-resolver-webpack”: “^0.12.1”, “eslint-plugin-import”: “^2.20.1”, “eslint-plugin-jsx-a11y”: “^6.2.3”, “eslint-plugin-react”: “^7.18.3”, “eslint-plugin-react-hooks”: “^2.3.0”, “eslint-plugin-sonarjs”: “^0.5.0”, “husky”: “^4.2.1”, “jest”: “^25.1.0”, “jest-cli”: “^25.1.0”, “jest-emotion”: “^10.0.27”, “jest-sonar-reporter”: “^2.0.0”, “node-sass”: “^4.13.1”, “open”: “^7.0.2”, “prop-types”: “^15.7.2”, “react”: “^16.12.0”, “react-dom”: “^16.12.0”, “sass-loader”: “^8.0.2”, “sort-package-json”: “^1.39.1”, “storybook-addon-emotion-theme”: “^2.1.1”, “style-loader”: “^1.1.3”, “webpack”: “^4.41.5”, “webpack-cli”: “^3.3.10” },

Error:

`info @storybook/react v5.3.11 info info => Loading static files from: /Users/xxx/Desktop/Workspace/node_modules/ info => Loading presets info => Loading presets info => Loading custom manager config. info => Loading config/preview file in “./.storybook”. info => Loading custom Webpack config (full-control mode). /Users/xxx/Desktop/Workspace/node_modules/@storybook/core/dist/server/dev-server.js:80 stats.toJson(options.errorDetails); ^

TypeError: Cannot read property ‘toJson’ of null at Watching.watch [as handler] (/Users/xxx/Desktop/Workspace/node_modules/@storybook/core/dist/server/dev-server.js:80:17) at Watching._done (/Users/xxx/Desktop/Workspace/node_modules/webpack/lib/Watching.js:95:9) at onCompiled (/Users/xxx/Desktop/Workspace/node_modules/webpack/lib/Watching.js:44:26) at hooks.beforeCompile.callAsync.err (/Users/xxx/Desktop/Workspace/node_modules/webpack/lib/Compiler.js:663:20) at _err0 (eval at create (/Users/xxx/Desktop/Workspace/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:9:1) at Array.compiler.inputFileSystem.readFile (/Users/xxx/Desktop/Workspace/node_modules/webpack/lib/DllReferencePlugin.js:54:24) at Storage.finished (/Users/xxx/Desktop/Workspace/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js:55:16) at ReadFileContext.provider (/Users/xxx/Desktop/Workspace/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js:91:9) at ReadFileContext.callback (/Users/xxx/Desktop/Workspace/node_modules/graceful-fs/graceful-fs.js:115:16) at FSReqWrap.readFileAfterOpen [as oncomplete] (fs.js:237:13)`

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 35
  • Comments: 31 (15 by maintainers)

Commits related to this issue

Most upvoted comments

Seeing the same error as OP on version 5.3.11.

Bumping down to version 5.3.10 worked for me.

Downgrading to 5.3.10 worked for me

Can somebody here please test the new release 5.3.12 and report back? I wasn’t able to repro the problem on my local machine. Thanks!

Just tested v5.3.12 and it fixed the issue for me.

(Small aside, you literally pushed the release as I was trying to find a solution, best response time ever ❤️ )

Not that it is really a big deal, but a thumbs up on the previous comments that are the exactly the same would probably suffice.

I pinged Shilman on discord to this issue. Hopefully he or another maintainer will see this soon.

Forcing to 5.3.10 without caret, works.

Yippee!! I just released https://github.com/storybookjs/storybook/releases/tag/v5.3.12 containing PR #9753 that references this issue. Upgrade today to try it out!

Closing this issue. Please re-open if you think there’s still more to do.

@profdangarcia - Delete node_modules, package-lock.json or yarn-lock.json, and replace the package versions in package.json like below:

@storybook/addon-a11y”: “5.3.10”, “@storybook/addon-actions”: “5.3.10”, “@storybook/addon-backgrounds”: “5.3.10”, “@storybook/addon-docs”: “5.3.10”, “@storybook/addon-info”: “5.3.10”, “@storybook/addon-knobs”: “5.3.10”, “@storybook/addon-storysource”: “5.3.10”, “@storybook/react”: “5.3.10”, “@storybook/source-loader”: “5.3.10”

No one has responded on the storybook discord about it. I know a lot of them don’t work in the USA, so maybe they’re not working right now. Best bet is to pin your @storybook versions to 5.3.10 until they address this.

oof this was killing me. Thanks all

Don’t have to downgrade addons, just @storybook/react: yarn add @storybook/react@5.3.10 -D solved this for me.