I tried using the generator in node 10.8.0 today, and every time the generator fails with the following error:
events.js:167
throw er; // Unhandled 'error' event
^
TypeError [ERR_INVALID_CALLBACK]: Callback must be a function
at maybeCallback (fs.js:127:9)
at Object.writeFile (fs.js:1123:14)
at child.configuring (/Users/cmalven/.nvm/versions/node/v10.8.0/lib/node_modules/generator-craftplugin/app/index.js:294:12)
at /Users/cmalven/.nvm/versions/node/v10.8.0/lib/node_modules/generator-craftplugin/node_modules/yeoman-generator/lib/base.js:429:16
at runCallback (timers.js:693:18)
at tryOnImmediate (timers.js:664:5)
at processImmediate (timers.js:646:5)
Emitted 'error' event at:
at /Users/cmalven/.nvm/versions/node/v10.8.0/lib/node_modules/generator-craftplugin/node_modules/yeoman-generator/lib/base.js:437:14
at runCallback (timers.js:693:18)
at tryOnImmediate (timers.js:664:5)
at processImmediate (timers.js:646:5)
Looking at the writeFile source code for the generator, it looks like that command doesn't actually have a callback param specified, but according to the most recent docs the callback param is required unless you're using writeFileSync.
I switched to node 8.11.0 and it worked fine, so could just be an API change in more recent node versions.
I tried using the generator in node
10.8.0
today, and every time the generator fails with the following error:Looking at the
writeFile
source code for the generator, it looks like that command doesn't actually have acallback
param specified, but according to the most recent docs thecallback
param is required unless you're usingwriteFileSync
.I switched to node
8.11.0
and it worked fine, so could just be an API change in more recent node versions.