TypeError:无法读取未定义的属性“笑话”

时间:2019-08-13 13:14:11

标签: feathersjs

我生成了一个新的feather应用程序,然后尝试向其添加服务,这给了我例外。

我正在节点版本10.16.2的Windows 10计算机上运行此程序

npm install -g feathers-cli

mkdir backend
cd backend

feathers generate app

? Project name | backend
? Description | contacts API server
? What folder should the source files live in? | src
? Which package manager are you using (has to be installed globally)? | Yarn
? What type of API are you making? | REST, Realtime via Socket.io

# Generate RESTful routes for Contact Model
feathers generate service

它给了我这个例外:

? What kind of service is it? KnexJS
? What is the name of the service? contact
? Which path should the service be registered on? /contacts
events.js:174
      throw er; // Unhandled 'error' event
      ^

TypeError: Cannot read property 'jest' of undefined
    at ServiceGenerator.writing (C:\Users\t965267\AppData\Roaming\npm\node_modules\@feathersjs\cli\node_modules\generator-feathers\generators\service\index.js:142:45)
    at Object.<anonymous> (C:\Users\t965267\AppData\Roaming\npm\node_modules\@feathersjs\cli\node_modules\yeoman-generator\lib\index.js:424:27)
    at C:\Users\t965267\AppData\Roaming\npm\node_modules\@feathersjs\cli\node_modules\run-async\index.js:25:25
    at new Promise (<anonymous>)
    at C:\Users\t965267\AppData\Roaming\npm\node_modules\@feathersjs\cli\node_modules\run-async\index.js:24:19
    at self.env.runLoop.add.completed (C:\Users\t965267\AppData\Roaming\npm\node_modules\@feathersjs\cli\node_modules\yeoman-generator\lib\index.js:425:13)
    at runCallback (timers.js:705:18)
    at tryOnImmediate (timers.js:676:5)
    at processImmediate (timers.js:658:5)
Emitted 'error' event at:
    at Immediate.setImmediate (C:\Users\t965267\AppData\Roaming\npm\node_modules\@feathersjs\cli\node_modules\yeoman-generator\lib\index.js:433:22)
    at runCallback (timers.js:705:18)
    at tryOnImmediate (timers.js:676:5)
    at processImmediate (timers.js:658:5)

0 个答案:

没有答案