Describe the bug
While working on #263, I tried to following the steps for local development (yarn install && yarn start). When doing so, I run into the following error:
yarn start error
```bash
ddelnano@vigenere:~/code/docs.px.dev (main) $ yarn start
yarn run v1.22.4
$ gatsby develop
‚ïî‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïó
‚ïë ‚ïë
‚ïë Gatsby collects anonymous usage analytics ‚ïë
‚ïë to help improve Gatsby for all users. ‚ïë
‚ïë ‚ïë
‚ïë If you'd like to opt-out, you can use `gatsby telemetry --disable` ‚ïë
‚ïë To learn more, checkout https://gatsby.dev/telemetry ‚ïë
‚ïë ‚ïë
‚ïö‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïê‚ïù
success open and validate gatsby-configs - 0.202s
ERROR #11329
Your plugins must export known APIs from their gatsby-node.js.
See https://www.gatsbyjs.org/docs/node-apis/ for the list of Gatsby node APIs.
- The plugin gatsby-plugin-sass@2.8.0 is using the API "pluginOptionsSchema" which was introduced in gatsby@2.25.0.
Some of the following may help fix the error(s):
- npm install gatsby@^2.25.0
success load plugins - 0.764s
success onPreInit - 0.007s
success initialize cache - 0.006s
success copy gatsby files - 0.019s
success onPreBootstrap - 0.011s
success createSchemaCustomization - 0.004s
warn Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db
success source and transform nodes - 7.478s
success building schema - 0.220s
success create redirects
success createPages - 5.227s
success createPagesStatefully - 0.078s
success onPreExtractQueries - 0.002s
success update schema - 0.054s
success extract queries from components - 0.296s
success write out requires - 0.056s
success write out redirect data - 0.010s
success onPostBootstrap - 0.014s
⠀
info bootstrap finished - 16.080s
⠀
success run static queries - 0.084s - 4/4 47.41/s
success run page queries - 0.703s - 328/328 466.50/s
ERROR
error:0308010C:digital envelope routines::unsupported
Error: error:0308010C:digital envelope routines::unsupported
- hash:71 new Hash
node:internal/crypto/hash:71:19
- node:crypto:133 Object.createHash
node:crypto:133:10
- createHash.js:135 module.exports
[docs.px.dev]/[webpack]/lib/util/createHash.js:135:53
- NormalModule.js:417 NormalModule._initBuildHash
[docs.px.dev]/[webpack]/lib/NormalModule.js:417:16
- NormalModule.js:452
[docs.px.dev]/[webpack]/lib/NormalModule.js:452:10
- NormalModule.js:323
[docs.px.dev]/[webpack]/lib/NormalModule.js:323:13
- LoaderRunner.js:367
[docs.px.dev]/[loader-runner]/lib/LoaderRunner.js:367:11
- LoaderRunner.js:233
[docs.px.dev]/[loader-runner]/lib/LoaderRunner.js:233:18
- LoaderRunner.js:111 context.callback
[docs.px.dev]/[loader-runner]/lib/LoaderRunner.js:111:13
- index.js:59
[docs.px.dev]/[babel-loader]/lib/index.js:59:103
error Command failed with exit code 1.
```
To Reproduce
Steps to reproduce the behavior:
Clone the repo
Run yarn install && yarn start
Expected behavior
Screenshots
N/A
Additional context
It appears this is an issue with webpack. https://github.com/webpack/webpack/issues/14532 describes how webpack 4 was broken by a OpenSSL nodejs change and that they did not intend to backport any fixes. So I believe the solution is to upgrade webpack.
We don't depend on webpack directly, but gatsy is pulling it in as seen in the yarn why output below.
$ yarn why webpack
yarn why v1.22.4
[1/4] Why do we have the module "webpack"...?
[2/4] Initialising dependency graph...
[3/4] Finding dependency...
[4/4] Calculating file sizes...
=> Found "webpack@4.43.0"
info Reasons this module exists
- "gatsby" depends on it
- Hoisted from "gatsby#webpack"
info Disk size without dependencies: "2.51MB"
info Disk size with unique dependencies: "9.92MB"
info Disk size with transitive dependencies: "27.18MB"
info Number of shared dependencies: 115
Done in 0.84s.
After talking with @NickLanam, I learned that the site is built with Node v14. That is prior to the v17 issues where the breaking openssl change occurred.
Describe the bug While working on #263, I tried to following the steps for local development (
yarn install && yarn start
). When doing so, I run into the following error:yarn start error
```bash ddelnano@vigenere:~/code/docs.px.dev (main) $ yarn start yarn run v1.22.4 $ gatsby develop ╔════════════════════════════════════════════════════════════════════════╗ ║ ║ ║ Gatsby collects anonymous usage analytics ║ ║ to help improve Gatsby for all users. ║ ║ ║ ║ If you'd like to opt-out, you can use `gatsby telemetry --disable` ║ ║ To learn more, checkout https://gatsby.dev/telemetry ║ ║ ║ ╚════════════════════════════════════════════════════════════════════════╝ success open and validate gatsby-configs - 0.202s ERROR #11329 Your plugins must export known APIs from their gatsby-node.js. See https://www.gatsbyjs.org/docs/node-apis/ for the list of Gatsby node APIs. - The plugin gatsby-plugin-sass@2.8.0 is using the API "pluginOptionsSchema" which was introduced in gatsby@2.25.0. Some of the following may help fix the error(s): - npm install gatsby@^2.25.0 success load plugins - 0.764s success onPreInit - 0.007s success initialize cache - 0.006s success copy gatsby files - 0.019s success onPreBootstrap - 0.011s success createSchemaCustomization - 0.004s warn Browserslist: caniuse-lite is outdated. Please run: npx browserslist@latest --update-db success source and transform nodes - 7.478s success building schema - 0.220s success create redirects success createPages - 5.227s success createPagesStatefully - 0.078s success onPreExtractQueries - 0.002s success update schema - 0.054s success extract queries from components - 0.296s success write out requires - 0.056s success write out redirect data - 0.010s success onPostBootstrap - 0.014s ⠀ info bootstrap finished - 16.080s ⠀ success run static queries - 0.084s - 4/4 47.41/s success run page queries - 0.703s - 328/328 466.50/s ERROR error:0308010C:digital envelope routines::unsupported Error: error:0308010C:digital envelope routines::unsupported - hash:71 new Hash node:internal/crypto/hash:71:19 - node:crypto:133 Object.createHash node:crypto:133:10 - createHash.js:135 module.exports [docs.px.dev]/[webpack]/lib/util/createHash.js:135:53 - NormalModule.js:417 NormalModule._initBuildHash [docs.px.dev]/[webpack]/lib/NormalModule.js:417:16 - NormalModule.js:452 [docs.px.dev]/[webpack]/lib/NormalModule.js:452:10 - NormalModule.js:323 [docs.px.dev]/[webpack]/lib/NormalModule.js:323:13 - LoaderRunner.js:367 [docs.px.dev]/[loader-runner]/lib/LoaderRunner.js:367:11 - LoaderRunner.js:233 [docs.px.dev]/[loader-runner]/lib/LoaderRunner.js:233:18 - LoaderRunner.js:111 context.callback [docs.px.dev]/[loader-runner]/lib/LoaderRunner.js:111:13 - index.js:59 [docs.px.dev]/[babel-loader]/lib/index.js:59:103 error Command failed with exit code 1. ```To Reproduce Steps to reproduce the behavior:
yarn install && yarn start
Expected behavior
Screenshots
N/A
Additional context
It appears this is an issue with webpack. https://github.com/webpack/webpack/issues/14532 describes how webpack 4 was broken by a OpenSSL nodejs change and that they did not intend to backport any fixes. So I believe the solution is to upgrade webpack.
We don't depend on webpack directly, but gatsy is pulling it in as seen in the
yarn why
output below.Environment
Until this issue is fixed, it can be worked around by setting
export NODE_OPTIONS=--openssl-legacy-provider
prior to runningyarn
.