window10安装taro成功后 初次运行 taro init mydemo 出错 提示(node:10828) UnhandledPromiseRejectionWarning: RangeError: Maximum call stack size exceeded



  • window10安装taro成功后 初次运行 taro init mydemo 出错 提示
    Taro v2.2.1

    (node:10828) UnhandledPromiseRejectionWarning: RangeError: Maximum call stack size exceeded
    at String.replace (<anonymous>)
    at normalizePath (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:25:37)
    at recursiveFindNodeModules (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:120:9)
    at recursiveFindNodeModules (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:133:12)
    at recursiveFindNodeModules (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:133:12)
    at recursiveFindNodeModules (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:133:12)
    at recursiveFindNodeModules (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:133:12)
    at recursiveFindNodeModules (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:133:12)
    at recursiveFindNodeModules (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:133:12)
    at recursiveFindNodeModules (F:\Program Files\nodejs\node_global\node_modules@tarojs\cli\node_modules@tarojs\helper\dist\utils.js:133:12)
    (node:10828) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)
    (node:10828) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.



  • npm版本是6.14.4 node.js 版本是v12.16.3和v12.16.1都试过 一样出现上面问题



  • 同样出现这个问题。。
    node8.x 不行。换成14.0.0也不行



  • 已经自己处理好了 是npm和yarn安装网络问题helper没有安装全 改成cnpm用管理员权限安装 就可以了



  • 给yarn或者npm换淘宝镜像源,然后重新安装下cli就行了。


登录后回复