我在创建运行项目而不运行项目时遇到一些错误

时间:2019-05-01 06:44:55

标签: android angular nativescript

我不知道会发生什么,也不知道解决方案是什么 项目未成功运行

我在命令中运行项目 tns cloud run android --accountId=1 --bundle --watch 并显示此错误

grandle_home环境设置以及ubuntu系统上设置的每个环境

Gradle build...

Exception in thread \"main\" 
java.io.IOException: Couldn't find '/mnt/storage/builds/_/b8da0e8899c968eb9ad76278a4fda4fec7160c46/5.3.4/5.3.1/toh6/platforms/android/build-tools/sbg-bindings.txt' bindings input file. Most probably there's an error in the JS Parser execution. You can run JS Parser with verbose logging by executing \"node '/mnt/storage/builds/_/b8da0e8899c968eb9ad76278a4fda4fec7160c46/5.3.4/5.3.1/toh6/platforms/android/build-tools/jsparser/js_parser.js' enableErrorLogging\".
\tat org.nativescript.staticbindinggenerator.Generator.generateBindings(Generator.java:126)
\tat org.nativescript.staticbindinggenerator.Generator.writeBindings(Generator.java:97)
\tat org.nativescript.staticbindinggenerator.Main.main(Main.java:48)
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:runSbg'.
> Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 1
* Try:
Run with --stacktrace
option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED
in 13s
Command ./gradlew failed with exit code 1
Exception in thread \"main\" java.io.IOException: Couldn't find '/mnt/storage/builds/_/b8da0e8899c968eb9ad76278a4fda4fec7160c46/5.3.4/5.3.1/toh6/platforms/android/build-tools/sbg-bindings.txt' bindings input file. Most probably there's an error in the JS Parser execution. You can run JS Parser with verbose logging by executing \"node '/mnt/storage/builds/_/b8da0e8899c968eb9ad76278a4fda4fec7160c46/5.3.4/5.3.1/toh6/platforms/android/build-tools/jsparser/js_parser.js' enableErrorLogging\".
\tat org.nativescript.staticbindinggenerator.Generator.generateBindings(Generator.java:126)
\tat org.nativescript.staticbindinggenerator.Generator.writeBindings(Generator.java:97)
\tat org.nativescript.staticbindinggenerator.Main.main(Main.java:48)
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:runSbg'.
> Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 1
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 13s
Command ./gradlew failed with exit code 1

bc_6V1Cl1Z7Xwv5wYvEdQ

Unable to apply changes on device: 4c3826b60805. Error is: Build failed. Reason is: 'Build failed with error code 2'. Additional information: [00:00:15.407] [WARN]  Exception in thread "main" 
[00:00:15.407] [WARN]  java.io.IOException: Couldn't find '/mnt/storage/builds/_/b8da0e8899c968eb9ad76278a4fda4fec7160c46/5.3.4/5.3.1/toh6/platforms/android/build-tools/sbg-bindings.txt' bindings input file. Most probably there's an error in the JS Parser execution. You can run JS Parser with verbose logging by executing "node '/mnt/storage/builds/_/b8da0e8899c968eb9ad76278a4fda4fec7160c46/5.3.4/5.3.1/toh6/platforms/android/build-tools/jsparser/js_parser.js' enableErrorLogging".
        at org.nativescript.staticbindinggenerator.Generator.generateBindings(Generator.java:126)
        at org.nativescript.staticbindinggenerator.Generator.writeBindings(Generator.java:97)
        at org.nativescript.staticbindinggenerator.Main.main(Main.java:48)

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:runSbg'.
> Process 'command '/usr/lib/jvm/java-8-oracle/bin/java'' finished with non-zero exit value 1

* Try:
Run with --stacktrace
[00:00:15.407] [WARN]   option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED
[00:00:15.409] [WARN]   in 13s

[00:00:15.782] [WARN]  Command ./gradlew failed with exit code 1

[00:00:16.277] [ERROR] Exception in thread "main" java.io.IOException: Couldn't find '/mnt/storage/builds/_/b8da0e8899c968eb9ad76278a4fda4fec7160c46/5.3.4/5.3.1/toh6/platforms/android/build-tools/sbg-bindings.txt' bindings input file. Most probably there's an error in the JS Parser execution. You can run JS Parser with verbose logging by executing "node '/mnt/storage/builds/_/b8da0e8899c968eb9ad76278a4fda4fec7160c46/5.3.4/5.3.1/toh6/platforms/android/build-tools/jsparser/js_parser.js' enableErrorLogging".
        at org.nativescript.staticbindinggenerator.Generator.generateBindings(Generator.java:126)
        at org.nativescript.staticbindinggenerator.Generator.writeBindings(Generator.java:97)
        at org.nativescript.staticbindinggenerator.Main.main(Main.java:48)

FAILURE: Build failed with an exception.

1 个答案:

答案 0 :(得分:0)

我解决了问题 安装gradle 点击此链接并逐步安装在gradle中 https://linuxize.com/post/how-to-install-gradle-on-ubuntu-18-04/