Closed tony closed 4 years ago
Thank you for reporting this @tony
Plugins depend on the lifecycle API, but Gatsby suddenly changed its behavior in the patch version. This breaks semantic versioning and I'm not sure what is the correct way to fix it.... :shrug:
I think using onPreBootstrap
instead of onPreExtractQueries
should fix it.
Fixed in v2.2.1
@cometkim Thank you! This fixed it for me!
Hi @cometkim! Thank you for the project!
I believe this issue came up here: https://github.com/gatsbyjs/gatsby/issues/25378 / https://github.com/gatsbyjs/gatsby/commit/e5ce35b
yarn.lock diff
version diff of gatsby packages that makes it begin:
```diff diff --git a/yarn.lock b/yarn.lock index 7160a838..8f072d9d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -9170,7 +9170,7 @@ functional-red-black-tree@^1.0.1: resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= -gatsby-cli@^2.12.58, gatsby-cli@^2.12.59: +gatsby-cli@^2.12.59: version "2.12.59" resolved "https://registry.yarnpkg.com/gatsby-cli/-/gatsby-cli-2.12.59.tgz#faa9a16c9dd6678473e0683256c39a97faa76322" integrity sha512-iQPFgBbZG1dLGtdNqB/gsnlwWu44rli/4J2VzYU3zwPguC9Zo3KMQxnrbIRY6CB1ryWQl+m/FZxO4umkEk8IUg== @@ -9364,7 +9364,7 @@ gatsby-plugin-offline@^3.2.16: lodash "^4.17.15" workbox-build "^4.3.1" -gatsby-plugin-page-creator@^2.3.15, gatsby-plugin-page-creator@^2.3.16: +gatsby-plugin-page-creator@^2.3.16: version "2.3.16" resolved "https://registry.yarnpkg.com/gatsby-plugin-page-creator/-/gatsby-plugin-page-creator-2.3.16.tgz#7280a1b7495697d38e213c1bfe6ce3fd2f80569a" integrity sha512-3HK0K+9yotRypNSeM/d2PlhW3YnFrQQ7MKF79sGSEM5x++9RiXYB1YbjibNw5rsM0SI/YCQqAAJi86kNU0B3SQ== @@ -9632,154 +9632,7 @@ gatsby-transformer-yaml@^2.4.9: lodash "^4.17.15" unist-util-select "^1.5.0" -gatsby@2.23.21: - version "2.23.21" - resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-2.23.21.tgz#44099dab466b12380c5ae4d6a92ce247119228ca" - integrity sha512-oR4E+v3ilih+hQ1KyDI9N9c5OUqpNyiw93vO2YCGnpIY+q2/ldUnjWQc9FLGgMxupNs9nnTtYT/UrpePHFQvzQ== - dependencies: - "@babel/code-frame" "^7.10.3" - "@babel/core" "^7.10.3" - "@babel/parser" "^7.10.3" - "@babel/polyfill" "^7.8.7" - "@babel/runtime" "^7.10.3" - "@babel/traverse" "^7.10.3" - "@hapi/joi" "^15.1.1" - "@mikaelkristiansson/domready" "^1.0.10" - "@pieh/friendly-errors-webpack-plugin" "1.7.0-chalk-2" - "@pmmmwh/react-refresh-webpack-plugin" "^0.3.3" - "@reach/router" "^1.3.4" - "@types/http-proxy" "^1.17.4" - "@typescript-eslint/eslint-plugin" "^2.24.0" - "@typescript-eslint/parser" "^2.24.0" - address "1.1.2" - autoprefixer "^9.8.4" - axios "^0.19.2" - babel-core "7.0.0-bridge.0" - babel-eslint "^10.1.0" - babel-loader "^8.1.0" - babel-plugin-add-module-exports "^0.3.3" - babel-plugin-dynamic-import-node "^2.3.3" - babel-plugin-remove-graphql-queries "^2.9.12" - babel-preset-gatsby "^0.5.1" - better-opn "1.0.0" - better-queue "^3.8.10" - bluebird "^3.7.2" - browserslist "^4.12.2" - cache-manager "^2.11.1" - cache-manager-fs-hash "^0.0.9" - chalk "^2.4.2" - chokidar "3.4.0" - common-tags "^1.8.0" - compression "^1.7.4" - convert-hrtime "^3.0.0" - copyfiles "^2.3.0" - core-js "^2.6.11" - cors "^2.8.5" - css-loader "^1.0.1" - date-fns "^2.14.0" - debug "^3.2.6" - del "^5.1.0" - detect-port "^1.3.0" - devcert "^1.1.0" - dotenv "^8.2.0" - eslint "^6.8.0" - eslint-config-react-app "^5.2.1" - eslint-loader "^2.2.1" - eslint-plugin-flowtype "^3.13.0" - eslint-plugin-graphql "^3.1.1" - eslint-plugin-import "^2.22.0" - eslint-plugin-jsx-a11y "^6.3.1" - eslint-plugin-react "^7.20.2" - eslint-plugin-react-hooks "^1.7.0" - event-source-polyfill "^1.0.15" - express "^4.17.1" - express-graphql "^0.9.0" - fast-levenshtein "^2.0.6" - file-loader "^1.1.11" - fs-exists-cached "1.0.0" - fs-extra "^8.1.0" - gatsby-cli "^2.12.58" - gatsby-core-utils "^1.3.11" - gatsby-graphiql-explorer "^0.4.10" - gatsby-link "^2.4.11" - gatsby-plugin-page-creator "^2.3.15" - gatsby-plugin-typescript "^2.4.13" - gatsby-react-router-scroll "^3.0.10" - gatsby-telemetry "^1.3.18" - glob "^7.1.6" - got "8.3.2" - graphql "^14.6.0" - graphql-compose "^6.3.8" - graphql-playground-middleware-express "^1.7.18" - hasha "^5.2.0" - http-proxy "^1.18.1" - invariant "^2.2.4" - is-relative "^1.0.0" - is-relative-url "^3.0.0" - is-wsl "^2.2.0" - jest-worker "^24.9.0" - json-loader "^0.5.7" - json-stringify-safe "^5.0.1" - latest-version "5.1.0" - lodash "^4.17.15" - md5-file "^3.2.3" - meant "^1.0.1" - micromatch "^3.1.10" - mime "^2.4.6" - mini-css-extract-plugin "^0.8.2" - mitt "^1.2.0" - mkdirp "^0.5.1" - moment "^2.27.0" - name-all-modules-plugin "^1.0.1" - normalize-path "^2.1.1" - null-loader "^3.0.0" - opentracing "^0.14.4" - optimize-css-assets-webpack-plugin "^5.0.3" - p-defer "^3.0.0" - parseurl "^1.3.3" - physical-cpu-count "^2.0.0" - pnp-webpack-plugin "^1.6.4" - postcss-flexbugs-fixes "^4.2.1" - postcss-loader "^3.0.0" - prompts "^2.3.2" - prop-types "^15.7.2" - query-string "^6.13.1" - raw-loader "^0.5.1" - react-dev-utils "^4.2.3" - react-error-overlay "^3.0.0" - react-hot-loader "^4.12.21" - react-refresh "^0.7.0" - redux "^4.0.5" - redux-thunk "^2.3.0" - semver "^5.7.1" - shallow-compare "^1.2.2" - signal-exit "^3.0.3" - slugify "^1.4.4" - socket.io "^2.3.0" - socket.io-client "2.3.0" - st "^2.0.0" - stack-trace "^0.0.10" - string-similarity "^1.2.2" - style-loader "^0.23.1" - terser-webpack-plugin "^1.4.4" - tmp "^0.2.1" - "true-case-path" "^2.2.1" - type-of "^2.0.1" - url-loader "^1.1.2" - util.promisify "^1.0.1" - uuid "^3.4.0" - v8-compile-cache "^1.1.2" - webpack "~4.43.0" - webpack-dev-middleware "^3.7.2" - webpack-dev-server "^3.11.0" - webpack-hot-middleware "^2.25.0" - webpack-merge "^4.2.2" - webpack-stats-plugin "^0.3.1" - webpack-virtual-modules "^0.2.2" - xstate "^4.11.0" - yaml-loader "^0.6.0" - -gatsby@>2.20.00: +gatsby@2.23.22, gatsby@>2.20.00: version "2.23.22" resolved "https://registry.yarnpkg.com/gatsby/-/gatsby-2.23.22.tgz#40260b744c0d1537d5cad03c9d57f86fce67cf3f" integrity sha512-3kQUOeYZDle17tgvBD8DHIv2jjjKISV6c/+adRPxIBtcsA/zc+otrLXDD8PL77jd2xiE8X7/lMq2O4LsvOx+qQ== ```