В этой сборке использовались устаревшие функции Gradle, что делает ее несовместимой с Gradle 6 - PullRequest
3 голосов
/ 23 июня 2019

Я пытаюсь получить Apk в Reaction-native, но это ничего не дает.Файл релиза, который находится в файле Apk, пуст, и после того, как выпуск пакета Gradlew закончен, он говорит:

    Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.4.1/userguide/command_line_interface.html#sec:command_line_warnings

Я не мог найти, как решить эту проблему

    react-native run-android
info Starting JS server...
info Building and installing the app on the device (cd android && ./gradlew app:installDebug)...
Starting a Gradle Daemon, 2 incompatible and 1 stopped Daemons could not be reused, use --status for details
> Task :app:transformClassesWithDexBuilderForDebug FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:transformClassesWithDexBuilderForDebug'.
> java.nio.file.AccessDeniedException: /home/kourosh/Projects/FitnessApp/android/app/build/intermediates/transforms/dexBuilder/debug/45/androidx/versionedparcelable/R.dex

* 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

Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.4.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 1m 15s
19 actionable tasks: 1 executed, 18 up-to-date
error Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/getting-started.html
error Command failed: ./gradlew app:installDebug. Run CLI with --verbose flag for more details.

java version "12.0.1 "узел 2019-04-16 -v v10.16.0 npm -v 6.9.0

1 Ответ

0 голосов
/ 19 июля 2019

Вы пробовали запустить ./gradlew bundleRelease --warning-mode all?

Это даст вам больше информации о том, что несовместимо.

...