在从一个空目录执行‘function’命令以创建一个azure函数时,会出现以下错误:
events.js:298
throw er; // Unhandled 'error' event
^
Error: spawn C:\Users\<XYZ>\AppData\Roaming\npm\node_modules\azure-functions-core-tools\bin/func ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:267:19)
at onErrorNT (internal/child_process.js:467:16)
at processTicksAndRejections (internal/process/task_queues.js:84:21)
Emitted 'error' event on ChildProcess instance at:
at Process.ChildProcess._handle.onexit (internal/child_process.js:273:12)
at onErrorNT (internal/child_process.js:467:16)
at processTicksAndRejections (internal/process/task_queues.js:84:21) {
errno: -4058,
code: 'ENOENT',
syscall: 'spawn C:\\Users\\<XYZ>\\AppData\\Roaming\\npm\\node_modules\\azure-functions-core-tools\\bin/func',
path: 'C:\\Users\\<XYZ>\\AppData\\Roaming\\npm\\node_modules\\azure-functions-core-tools\\bin/func',
spawnargs: [ 'init' ]
}有人对此有什么建议吗?
发布于 2020-02-11 09:19:44
感谢您的更新@静默。在谷歌上搜索同样的内容,我也进入了同样的链接。
为了跟进Github的建议,我必须执行以下步骤:
C:\Users\< XYZ >\AppData\Roaming\npm\node_modules\azure-functions-core-tools "dependencies": {
"chalk": "3.0.0",
"command-exists": "1.2.8",
"glob": "7.1.6",
"https-proxy-agent": "3.0.1",
"progress": "2.0.3",
"rimraf": "3.0.0",
"tmp": "0.1.0",
"unzipper": "0.10.8"
},在directory.
上此目录下的
记住在机器上将"< XYZ >“替换为您自己的用户名。
https://stackoverflow.com/questions/60149342
复制相似问题