首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何使用--stracktrace选项运行,以便可以运行react-native-cli项目

如何使用--stracktrace选项运行,以便可以运行react-native-cli项目
EN

Stack Overflow用户
提问于 2021-08-15 23:39:55
回答 1查看 164关注 0票数 0

我有一个关于运行React-native-cli项目的问题。当我运行以下命令:npx react-native run-android时,它返回以下结果:

代码语言:javascript
复制
info Installing the app...
> Task :app:generatePackageList FAILED

Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

See https://docs.gradle.org/7.1.1/userguide/command_line_interface.html#sec:command_line_warnings
1 actionable task: 1 executed

FAILURE: Build failed with an exception.

* Where:
Script 'D:\IT\React.js\JAMK\e06Movies\node_modules\@react-native-community\cli-platform-android\native_modules.gradle' line: 131

* What went wrong:
Execution failed for task ':app:generatePackageList'.
> argument type mismatch

* 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 6s

error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081

FAILURE: Build failed with an exception.

* Where:
Script 'D:\IT\React.js\JAMK\e06Movies\node_modules\@react-native-community\cli-platform-android\native_modules.gradle' line: 131

* What went wrong:
Execution failed for task ':app:generatePackageList'.
> argument type mismatch

* 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 6s

    at makeError (D:\IT\React.js\JAMK\e06Movies\node_modules\execa\index.js:174:9)
    at D:\IT\React.js\JAMK\e06Movies\node_modules\execa\index.js:278:16
    at processTicksAndRejections (node:internal/process/task_queues:94:5)
    at async runOnAllDevices (D:\IT\React.js\JAMK\e06Movies\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\runOnAllDevices.js:94:5)
    at async Command.handleAction (D:\IT\React.js\JAMK\e06Movies\node_modules\@react-native-community\cli\build\index.js:186:9)
info Run CLI with --verbose flag for more details.

我在Android Studio中通过以下指令添加了--stacktrace:"https://stackoverflow.com/questions/21674091/how-to-add-stacktrace-or-debug-option-when-building-android-studio-project“,但它根本不起作用。

有人能给我一些解决这个问题的建议吗?非常感谢!

EN

回答 1

Stack Overflow用户

发布于 2021-08-15 23:41:18

npx react-native run-android --verbose

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/68796104

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档