#1544·gridsome

Gridsome won't build – Cannot read property 'tapAsync' of undefined

Author: djmtypeCreated Aug 13, 2021Updated Nov 23, 2023

Description

My project use to build on a Mac Intel with Node v14.15.

However, Gridsome won't build with Node v15.0.1. I'm also now on an M1 Mac. I had previously fixed the Sharp issue. I removed the package-lock.json file, node modules, etc. Now when trying to run gridsome build, I get the following:

(BTW, Gridsome will still run in development gridsome develop.)

(node:26617) ExperimentalWarning: AbortController is an experimental feature. This feature could change at any time
(Use `node --trace-warnings ...` to show where the warning was created)
Create GraphQL schema - 19.53s
Create pages and templates - 4.75s
Generate temporary code - 0.04s
Bootstrap finish - 27.18s
0% compilingTypeError: Cannot read property 'tapAsync' of undefined
    at /Volumes/Evo/Sites/mtype-alpha/node_modules/vue-server-renderer/server-plugin.js:52:39
    at SyncHook.eval [as call] (eval at create (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:19:10), <anonymous>:13:1)
    at SyncHook.lazyCompileHook (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/node_modules/tapable/lib/Hook.js:154:20)
    at Compiler.newCompilation (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/lib/Compiler.js:631:26)
    at /Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/lib/Compiler.js:667:29
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1)
    at AsyncSeriesHook.lazyCompileHook (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/node_modules/tapable/lib/Hook.js:154:20)
    at Compiler.compile (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/lib/Compiler.js:662:28)
    at /Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/lib/Compiler.js:321:11
    at Compiler.readRecords (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/lib/Compiler.js:529:11)
    at /Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/lib/Compiler.js:318:10
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1)
    at AsyncSeriesHook.lazyCompileHook (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/node_modules/tapable/lib/Hook.js:154:20)
    at /Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/lib/Compiler.js:315:19
    at AsyncSeriesHook.eval [as callAsync] (eval at create (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:15:1)
    at AsyncSeriesHook.lazyCompileHook (/Volumes/Evo/Sites/mtype-alpha/node_modules/gridsome/node_modules/webpack/node_modules/tapable/lib/Hook.js:154:20)

Paste the information here as shown by gridsome info

System:
    OS: macOS 11.4
    CPU: (8) arm64 Apple M1
  Binaries:
    Node: 15.0.1 - ~/.nvm/versions/node/v15.0.1/bin/node
    Yarn: 1.22.11 - /opt/homebrew/bin/yarn
    npm: 7.0.3 - ~/.nvm/versions/node/v15.0.1/bin/npm
  Browsers:
    Chrome: 92.0.4515.131
    Firefox: 91.0
    Safari: 14.1.1
  npmPackages:
    @gridsome/remark-prismjs: ^0.5.0 => 0.5.0
    @gridsome/source-filesystem: ^0.6.2 => 0.6.2
    @gridsome/source-graphql: ^0.1.0 => 0.1.0
    @gridsome/transformer-remark: ^0.6.4 => 0.6.4
    gridsome: ^0.7.0 => 0.7.23
    gridsome-source-rss: ^1.0.0 => 1.0.0
    gridsome-source-static-meta: ^1.0.1 => 1.0.1