Невозможно запустить собственную реакцию- android на Mac - PullRequest
1 голос
/ 30 января 2020

У меня на iMa c есть полная собственная реакционная среда, проект запускается полностью, когда я запускаю реактивный собственный запуск - ios, но когда я сделаю это с android, он не будет работать, окно metro bundler открывается, но не работает и не появляется никаких сообщений.

Что мне нужно сделать?

Мой терминал после того, как я запустил "response-native run- android"

Daives-iMac:generico_toaqui_app fourtime$ react-native run-android
warn The following packages use deprecated "rnpm" config that will stop working from next release:
  - react-native-code-push: https://microsoft.github.io/code-push
  - react-native-maps: https://github.com/react-native-community/react-native-maps#readme
Please notify their maintainers about it. You can find more details at https://github.com/react-native-community/cli/blob/master/docs/configuration.md#migration-guide.
error React Native CLI uses autolinking for native dependencies, but the following modules are linked manually: 
  - @react-native-community/netinfo (to unlink run: "react-native unlink @react-native-community/netinfo")
  - bugsnag-react-native (to unlink run: "react-native unlink bugsnag-react-native")
  - react-native-camera (to unlink run: "react-native unlink react-native-camera")
  - react-native-code-push (to unlink run: "react-native unlink react-native-code-push")
  - react-native-contacts (to unlink run: "react-native unlink react-native-contacts")
  - react-native-device-info (to unlink run: "react-native unlink react-native-device-info")
  - react-native-firebase (to unlink run: "react-native unlink react-native-firebase")
  - react-native-fs (to unlink run: "react-native unlink react-native-fs")
  - react-native-image-picker (to unlink run: "react-native unlink react-native-image-picker")
  - react-native-image-resizer (to unlink run: "react-native unlink react-native-image-resizer")
  - react-native-maps (to unlink run: "react-native unlink react-native-maps")
  - react-native-otp-verify (to unlink run: "react-native unlink react-native-otp-verify")
  - react-native-power-saving-mode (to unlink run: "react-native unlink react-native-power-saving-mode")
  - react-native-vector-icons (to unlink run: "react-native unlink react-native-vector-icons")
  - rethink-gpstracking (to unlink run: "react-native unlink rethink-gpstracking")
  - rethink-material-design (to unlink run: "react-native unlink rethink-material-design")
This is likely happening when upgrading React Native from below 0.60 to 0.60 or above. Going forward, you can unlink this dependency via "react-native unlink <dependency>" and it will be included in your app automatically. If a library isn't compatible with autolinking, disregard this message and notify the library maintainers.
Read more about autolinking: https://github.com/react-native-community/cli/blob/master/docs/autolinking.md
info Running jetifier to migrate libraries to AndroidX. You can disable it using "--no-jetifier" flag.
Jetifier found 1891 file(s) to forward-jetify. Using 4 workers...
info Starting JS server...
info Installing the app...
Starting a Gradle Daemon, 1 incompatible and 2 stopped Daemons could not be reused, use --status for details

> Configure project :app
Could not find google-services.json while looking in [src/nullnull/debug, src/debug/nullnull, src/nullnull, src/debug, src/nullnullDebug]
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)
Could not find google-services.json while looking in [src/nullnull/release, src/release/nullnull, src/nullnull, src/release, src/nullnullRelease]
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)
Could not find google-services.json while looking in [src/nullnull/releaseStaging, src/releaseStaging/nullnull, src/nullnull, src/releaseStaging, src/nullnullReleaseStaging]
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)

> Configure project :react-native-firebase
react-native-firebase: using React Native prebuilt binary from /Users/fourtime/Documents/React Native/generico_toaqui_app/node_modules/react-native/android

> Configure project :react-native-image-resizer
WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'.
It will be removed soon. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html

> Configure project :react-native-power-saving-mode
WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'.
It will be removed soon. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html

> Configure project :rethink-gpstracking
WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'.
It will be removed soon. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html

> Configure project :rethink-material-design
WARNING: The following project options are deprecated and have been removed: 
android.useDeprecatedNdk
NdkCompile is no longer supported


WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'.
It will be removed soon. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html

> Configure project :rethink-utils
WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'.
It will be removed soon. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html
WARNING: The specified Android SDK Build Tools version (26.0.3) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.5.3.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '26.0.3'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.
WARNING: The specified Android SDK Build Tools version (26.0.3) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.5.3.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '26.0.3'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.
WARNING: The specified Android SDK Build Tools version (27.0.3) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.5.3.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '27.0.3'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.
WARNING: The specified Android SDK Build Tools version (28.0.2) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.5.3.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '28.0.2'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.
WARNING: The specified Android SDK Build Tools version (23.0.3) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.5.3.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '23.0.3'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.
WARNING: The specified Android SDK Build Tools version (23.0.1) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.5.3.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '23.0.1'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.
WARNING: The specified Android SDK Build Tools version (23.0.1) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.5.3.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '23.0.1'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.
WARNING: The specified Android SDK Build Tools version (23.0.1) is ignored, as it is below the minimum supported version (28.0.3) for Android Gradle Plugin 3.5.3.
Android SDK Build Tools 28.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '23.0.1'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.

> Task :app:processDebugGoogleServices
Parsing json file: /Users/fourtime/Documents/React Native/generico_toaqui_app/android/app/google-services.json

> Task :app:processDebugManifest
/Users/fourtime/Documents/React Native/generico_toaqui_app/android/app/src/debug/AndroidManifest.xml:24:9-31:50 Warning:
        activity#com.google.firebase.auth.internal.FederatedSignInActivity@android:launchMode was tagged at AndroidManifest.xml:24 to replace other declarations but no other declaration present

> Task :app:stripDebugDebugSymbols UP-TO-DATE
Compatible side by side NDK version was not found.

> Task :app:installDebug
04:58:49 V/ddms: execute: running am get-config
04:58:50 V/ddms: execute 'am get-config' on 'S541008694' : EOF hit. Read: -1
04:58:50 V/ddms: execute: returning
Installing APK 'app-debug.apk' on 'Twist 2 Go - 8.1.0' for app:debug
04:58:50 D/app-debug.apk: Uploading app-debug.apk onto device 'S541008694'
04:58:50 D/Device: Uploading file onto device 'S541008694'
04:58:50 D/ddms: Reading file permision of /Users/fourtime/Documents/React Native/generico_toaqui_app/android/app/build/outputs/apk/debug/app-debug.apk as: rw-r--r--
04:58:52 V/ddms: execute: running pm install -r -t "/data/local/tmp/app-debug.apk"
04:59:07 V/ddms: execute 'pm install -r -t "/data/local/tmp/app-debug.apk"' on 'S541008694' : EOF hit. Read: -1
04:59:07 V/ddms: execute: returning
04:59:07 V/ddms: execute: running rm "/data/local/tmp/app-debug.apk"
04:59:08 V/ddms: execute 'rm "/data/local/tmp/app-debug.apk"' on 'S541008694' : EOF hit. Read: -1
04:59:08 V/ddms: execute: returning
Installed on 1 device.

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 SUCCESSFUL in 2m 2s
485 actionable tasks: 9 executed, 476 up-to-date
/bin/sh: adb: command not found
info Connecting to the development server...
warn Failed to connect to development server using "adb reverse": spawnSync adb ENOENT
info Starting the app...

Экран печати моего терминала после того, как я запустил android и под ним мой пакет метро

Ответы [ 3 ]

0 голосов
/ 01 февраля 2020

Судя по всему, я могу почувствовать две проблемы:

error React Native CLI использует автосвязь для собственных зависимостей, но следующие модули связаны вручную:

поскольку вы используете RN 0,60 или выше, он может автоматически связывать определенные библиотеки для вас, вы можете безопасно отсоединить эти библиотеки. Попробуйте взглянуть на this

/ bin / sh: adb: команда не найдена

кажется, что команда adb недоступна для npm, для этого взгляните на это

0 голосов
/ 18 февраля 2020

Похоже, вы не включили "NDK рядом" для этой ошибки:

Совместимая версия бок о бок NDK не найдена.

Откройте вашу Android Studio и установите инструмент «NDK (бок о бок)»: Android Studio -> Tools -> SDK Manager -> SDK Tools

Затем: react-native run-android

Надеюсь, эта помощь.

0 голосов
/ 31 января 2020

Вы пробовали это Установка ADB на macOS ? После этого убедитесь, что вы запускаете эмулятор, а затем выполняете собственную реакцию- android

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...