它无法检测到cordova,但已安装并且其他项目正常运行

时间:2018-12-14 08:37:16

标签: android gradle compiler-errors ionic3

我不知道可能会发生什么。我在IONIC中还有其他项目可以正常工作,但是由于某种原因,当尝试生成此版本的Android版本时,出现此错误。我找到的所有答案都是针对未安装Android Studio / Gradle的用户的,但这不是这种情况

JAVA_HOME=C:\Program Files\Java\jdk1.8.0_121
studio
(node:9388) UnhandledPromiseRejectionWarning: CordovaError: Could not find an installed version of Gradle either in Android Studio,
or on your system to install the gradle wrapper. Please include gradle
in your path, or install Android Studio
    at Object.module.exports.check_gradle (D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\lib\check_reqs.js:150:18)
    at StudioBuilder.prepEnv (D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\lib\builders\StudioBuilder.js:216:23)
    at Api.module.exports.run (D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\lib\build.js:154:20)
    at D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\Api.js:342:43
    at _fulfilled (D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\node_modules\q\q.js:854:54)
    at D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\node_modules\q\q.js:883:30
    at Promise.promise.promiseDispatch (D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\node_modules\q\q.js:816:13)
    at D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\node_modules\q\q.js:624:44
    at runSingle (D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\node_modules\q\q.js:137:13)
    at flush (D:\Clientes\proj\eComerce Ropa\app\platforms\android\cordova\node_modules\q\q.js:125:13)
(node:9388) 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(). (rejection id: 1)
(node:9388) [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.

预先感谢

编辑:

gradle -v

------------------------------------------------------------
Gradle 5.0
------------------------------------------------------------

Build time:   2018-11-26 11:48:43 UTC
Revision:     7fc6e5abf2fc5fe0824aec8a0f5462664dbcd987

Kotlin DSL:   1.0.4
Kotlin:       1.3.10
Groovy:       2.5.4
Ant:          Apache Ant(TM) version 1.9.13 compiled on July 10 2018
JVM:          1.8.0_121 (Oracle Corporation 25.121-b13)
OS:           Windows 10 10.0 amd64

0 个答案:

没有答案