按照官方文档正常操作: 走了一下 构建方式 $ mkdir showcase && cd showcase $ npm init egg --type=ts $ npm i $ npm run tsc $ npm start
然后就报错了, 具体错误信息如下:
是不是模板本身就有问题???
最小可复现仓库复现步骤,错误日志以及相关配置请使用
npm init egg --type=simple bug创建,并上传到你的 GitHub 仓库
egg-scripts] tail -n 100 /Users/wanganming/logs/master-stderr.log
[egg-scripts] Got error when startup:
[egg-scripts] at checkWaitingCount (internal/cluster/child.js:217:9)
[egg-scripts] at Worker._disconnect (internal/cluster/child.js:232:3)
[egg-scripts] at Worker.disconnect (internal/cluster/child.js:239:5)
[egg-scripts] at process. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/graceful/index.js:101:16)
[egg-scripts] at process.emit (events.js:376:20)
[egg-scripts] at process.emit (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-scripts/node_modules/source-map-support/source-map-support.js:516:21)
[egg-scripts] [Sun Jan 23 2022 17:26:58 GMT+0800 (中国标准时间)] [graceful:worker:46735:uncaughtException] throw error 3 times
[egg-scripts] Error: write EPIPE
[egg-scripts] at process.target._send (internal/child_process.js:839:20)
[egg-scripts] at process.target.send (internal/child_process.js:710:19)
[egg-scripts] at sendHelper (internal/cluster/utils.js:27:15)
[egg-scripts] at send (internal/cluster/child.js:199:10)
[egg-scripts] at checkWaitingCount (internal/cluster/child.js:217:9)
[egg-scripts] at Worker._disconnect (internal/cluster/child.js:232:3)
[egg-scripts] at Worker.disconnect (internal/cluster/child.js:239:5)
[egg-scripts] at process. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/graceful/index.js:101:16)
[egg-scripts] at process.emit (events.js:376:20)
[egg-scripts] at process.emit (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-scripts/node_modules/source-map-support/source-map-support.js:516:21) {
[egg-scripts] errno: -32,
[egg-scripts] code: 'EPIPE',
[egg-scripts] syscall: 'write',
[egg-scripts] name: 'EPIPEError'
[egg-scripts] }
[egg-scripts] Error: write EPIPE
[egg-scripts] at process.target._send (internal/child_process.js:839:20)
[egg-scripts] at process.target.send (internal/child_process.js:710:19)
[egg-scripts] at sendHelper (internal/cluster/utils.js:27:15)
[egg-scripts] at send (internal/cluster/child.js:199:10)
[egg-scripts] at checkWaitingCount (internal/cluster/child.js:217:9)
[egg-scripts] at Worker._disconnect (internal/cluster/child.js:232:3)
[egg-scripts] at Worker.disconnect (internal/cluster/child.js:239:5)
[egg-scripts] at process. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/graceful/index.js:101:16)
[egg-scripts] at process.emit (events.js:376:20)
[egg-scripts] at process.emit (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-scripts/node_modules/source-map-support/source-map-support.js:516:21)
[egg-scripts] Error: write EPIPE
[egg-scripts] at process.target._send (internal/child_process.js:839:20)
[egg-scripts] at process.target.send (internal/child_process.js:710:19)
[egg-scripts] at Object. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-cluster/lib/app_worker.js:34:9)
[egg-scripts] at Module._compile (internal/modules/cjs/loader.js:1068:30)
[egg-scripts] at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)
[egg-scripts] at Module.load (internal/modules/cjs/loader.js:933:32)
[egg-scripts] at Function.Module._load (internal/modules/cjs/loader.js:774:14)
[egg-scripts] at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
[egg-scripts] at internal/main/run_main_module.js:17:47
[egg-scripts] 2022-01-23 17:26:58,469 ERROR 46744 [app_worker] exit with code:1
[egg-scripts] Error: write EPIPE
[egg-scripts] at process.target._send (internal/child_process.js:839:20)
[egg-scripts] at process.target.send (internal/child_process.js:710:19)
[egg-scripts] at Object. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-cluster/lib/app_worker.js:34:9)
[egg-scripts] at Module._compile (internal/modules/cjs/loader.js:1068:30)
[egg-scripts] at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)
[egg-scripts] at Module.load (internal/modules/cjs/loader.js:933:32)
[egg-scripts] at Function.Module._load (internal/modules/cjs/loader.js:774:14)
[egg-scripts] at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
[egg-scripts] at internal/main/run_main_module.js:17:47
[egg-scripts] 2022-01-23 17:26:58,471 ERROR 46739 [app_worker] exit with code:1
[egg-scripts] Error: write EPIPE
[egg-scripts] at process.target._send (internal/child_process.js:839:20)
[egg-scripts] at process.target.send (internal/child_process.js:710:19)
[egg-scripts] at Object. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-cluster/lib/app_worker.js:34:9)
[egg-scripts] at Module._compile (internal/modules/cjs/loader.js:1068:30)
[egg-scripts] at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)
[egg-scripts] at Module.load (internal/modules/cjs/loader.js:933:32)
[egg-scripts] at Function.Module._load (internal/modules/cjs/loader.js:774:14)
[egg-scripts] at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
[egg-scripts] at internal/main/run_main_module.js:17:47
[egg-scripts] 2022-01-23 17:26:58,475 ERROR 46741 [app_worker] exit with code:1
[egg-scripts] Error: write EPIPE
[egg-scripts] at process.target._send (internal/child_process.js:839:20)
[egg-scripts] at process.target.send (internal/child_process.js:710:19)
[egg-scripts] at Object. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-cluster/lib/app_worker.js:34:9)
[egg-scripts] at Module._compile (internal/modules/cjs/loader.js:1068:30)
[egg-scripts] at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)
[egg-scripts] at Module.load (internal/modules/cjs/loader.js:933:32)
[egg-scripts] at Function.Module._load (internal/modules/cjs/loader.js:774:14)
[egg-scripts] at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
[egg-scripts] at internal/main/run_main_module.js:17:47
[egg-scripts] 2022-01-23 17:26:58,478 ERROR 46746 [app_worker] exit with code:1
[egg-scripts] Error: write EPIPE
[egg-scripts] at process.target._send (internal/child_process.js:839:20)
[egg-scripts] at process.target.send (internal/child_process.js:710:19)
[egg-scripts] at Object. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-cluster/lib/app_worker.js:34:9)
[egg-scripts] at Module._compile (internal/modules/cjs/loader.js:1068:30)
[egg-scripts] at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)
[egg-scripts] at Module.load (internal/modules/cjs/loader.js:933:32)
[egg-scripts] at Function.Module._load (internal/modules/cjs/loader.js:774:14)
[egg-scripts] at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
[egg-scripts] at internal/main/run_main_module.js:17:47
[egg-scripts] 2022-01-23 17:26:58,479 ERROR 46745 [app_worker] exit with code:1
[egg-scripts] Error: write EPIPE
[egg-scripts] at process.target._send (internal/child_process.js:839:20)
[egg-scripts] at process.target.send (internal/child_process.js:710:19)
[egg-scripts] at Object. (/Users/wanganming/Documents/anmingwang/temp/koa-egg/node_modules/egg-cluster/lib/app_worker.js:34:9)
[egg-scripts] at Module._compile (internal/modules/cjs/loader.js:1068:30)
[egg-scripts] at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)
[egg-scripts] at Module.load (internal/modules/cjs/loader.js:933:32)
[egg-scripts] at Function.Module._load (internal/modules/cjs/loader.js:774:14)
[egg-scripts] at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
[egg-scripts] at internal/main/run_main_module.js:17:47
[egg-scripts] 2022-01-23 17:26:58,484 ERROR 46742 [app_worker] exit with code:1
[egg-scripts]
[egg-scripts] Start got error, see /Users/wanganming/logs/master-stderr.log
[egg-scripts] Or use --ignore-stderr to ignore stderr at startup.- 操作系统: MacOS
- Node 版本:v14.17.0
- Egg 版本:"^2.6.1",
