Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not find any matches for com.facebook.react:react-android:+ as no versions of com.facebook.react:react-android are available #1977

Closed
3 of 5 tasks
caolong0204 opened this issue Oct 11, 2023 · 6 comments
Labels
🔧 build error Issue is related to building VisionCamera in your project

Comments

@caolong0204
Copy link

How were you trying to build the app?

Everything worked well after i upgrade version lib react-native-vision-camera to 3.3.1
I did new implementing way and ios run ok but i meet error in android

I tried build with command yarn android

Full build logs

> Configure project :react-native-vision-camera
[VisionCamera] react-native-worklets-core not found, Frame Processors disabled!

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.3.3/userguide/command_line_interface.html#sec:command_line_warnings
6 actionable tasks: 6 up-to-date
Warning: This version only understands SDK XML versions up to 2 but an SDK XML file of version 3 was encountered. This can happen if you use versions of Android Studio and the command-line tools that were released at different times.
Warning: unexpected element (uri:"", local:"extension-level"). Expected elements are <{}codename>,<{}layoutlib>,<{}api-level>
Warning: unexpected element (uri:"", local:"base-extension"). Expected elements are <{}codename>,<{}layoutlib>,<{}api-level>

FAILURE: Build failed with an exception.

* What went wrong:
Could not determine the dependencies of task ':app:mergeDevelopmentDebugAssets'.
> Could not resolve all task dependencies for configuration ':app:developmentDebugRuntimeClasspath'.
   > Could not find any matches for com.facebook.react:react-android:+ as no versions of com.facebook.react:react-android are available.
     Searched in the following locations:
       - file:/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/react-native/android/com/facebook/react/react-android/maven-metadata.xml
       - file:/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/jsc-android/dist/com/facebook/react/react-android/maven-metadata.xml
       - https://dl.google.com/dl/android/maven2/com/facebook/react/react-android/maven-metadata.xml
       - https://www.jitpack.io/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/FREEKEY-DK-SDK_SDX_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/FREEKEY-DK-SDK_PRD_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/DK-SDK_SDX_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/DK-SDK_PRD_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/TOKAIRIKA-QEYBASE-SDK/CRYPTO-SDK-SDX_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/TOKAIRIKA-QEYBASE-SDK/QEYBASE-SDK-SDX_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/TOKAIRIKA-QEYBASE-SDK/QEYBASE-SDK-PRD_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/HITSERIES-FREEKEY-CRYPTO/QEYBASE-SDK-STG_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/FREEKEY-DK-SDK_SDX-DKPRD_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - file:/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/@notifee/react-native/android/libs/com/facebook/react/react-android/maven-metadata.xml
     Required by:
         project :app > project :react-native-vision-camera

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

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 app:installDevelopmentdebug -PreactNativeDevServerPort=8081
Warning: This version only understands SDK XML versions up to 2 but an SDK XML file of version 3 was encountered. This can happen if you use versions of Android Studio and the command-line tools that were released at different times.
Warning: unexpected element (uri:"", local:"extension-level"). Expected elements are <{}codename>,<{}layoutlib>,<{}api-level>
Warning: unexpected element (uri:"", local:"base-extension"). Expected elements are <{}codename>,<{}layoutlib>,<{}api-level>

FAILURE: Build failed with an exception.

* What went wrong:
Could not determine the dependencies of task ':app:mergeDevelopmentDebugAssets'.
> Could not resolve all task dependencies for configuration ':app:developmentDebugRuntimeClasspath'.
   > Could not find any matches for com.facebook.react:react-android:+ as no versions of com.facebook.react:react-android are available.
     Searched in the following locations:
       - file:/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/react-native/android/com/facebook/react/react-android/maven-metadata.xml
       - file:/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/jsc-android/dist/com/facebook/react/react-android/maven-metadata.xml
       - https://dl.google.com/dl/android/maven2/com/facebook/react/react-android/maven-metadata.xml
       - https://www.jitpack.io/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/FREEKEY-DK-SDK_SDX_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/FREEKEY-DK-SDK_PRD_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/DK-SDK_SDX_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/DK-SDK_PRD_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/TOKAIRIKA-QEYBASE-SDK/CRYPTO-SDK-SDX_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/TOKAIRIKA-QEYBASE-SDK/QEYBASE-SDK-SDX_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/TOKAIRIKA-QEYBASE-SDK/QEYBASE-SDK-PRD_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/HITSERIES-FREEKEY-CRYPTO/QEYBASE-SDK-STG_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - https://raw.githubusercontent.com/DigiKey0001-01/FREEKEY-DK-SDK_SDX-DKPRD_Android/main/com/facebook/react/react-android/maven-metadata.xml
       - file:/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/@notifee/react-native/android/libs/com/facebook/react/react-android/maven-metadata.xml
     Required by:
         project :app > project :react-native-vision-camera

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

    at makeError (/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/execa/index.js:174:9)
    at /Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/execa/index.js:278:16
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async runOnAllDevices (/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/@react-native-community/cli-platform-android/build/commands/runAndroid/runOnAllDevices.js:109:5)
    at async Command.handleAction (/Users/tanaakkhcm/Documents/work/projects/Uqey/mobile/cloneRentCar/node_modules/@react-native-community/cli/build/index.js:192:9)
info Run CLI with --verbose flag for more details.

Project dependencies

"react-native": "0.68.2",
    "react-native-vision-camera": "3.3.1",
    "react-native-reanimated": "2.12.0",

VisionCamera Version

3.3.1

Target platforms

Android

Operating system

MacOS

Can you build the VisionCamera Example app?

I didn't try (⚠️ your issue might get ignored & closed if you don't try this)

Additional information

@caolong0204 caolong0204 added the 🔧 build error Issue is related to building VisionCamera in your project label Oct 11, 2023
@caolong0204 caolong0204 changed the title 🔧 [VisionCamera] react-native-worklets-core not found, Frame Processors disabled! Could not find any matches for com.facebook.react:react-android:+ as no versions of com.facebook.react:react-android are available Oct 11, 2023
@OPEN-9
Copy link

OPEN-9 commented Oct 11, 2023

2.16.2 I also encountered this error.

@zzz08900
Copy link
Contributor

zzz08900 commented Oct 11, 2023

Last time I tried, you need the latest version or RN to run vision-camera v2.16.2 or v3.
For older versions of RN, stick to 2.15.x

@mrousavy
Copy link
Owner

Did something happen with the RN upgrade? Many people are experiencing this, idk if there's something wrong with my build.gradle?

@zzz08900
Copy link
Contributor

zzz08900 commented Oct 11, 2023

I made a fresh install of RN0.72 and played with 3.3.1/2.16.2 a few hours ago and everything compiles and runs - not an empty toy project but one with a few dozen React pages and a lot of popular dependencies.
I did have a really bad time trying to get 3.3.1/2.16.2 work with RN0.68/0.69/0.71 though.

I feel like this could be a version incompatibility problem, or something went wrong during RN update process.

@mrousavy
Copy link
Owner

Oh yea I think you need RN 0.71 or higher!

@Virajmakwana
Copy link

Virajmakwana commented Dec 4, 2023

I am also facing this issue, my project is based on these versions
"react-native": "^0.68.2",
"react-native-vision-camera": "^3.6.12",

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔧 build error Issue is related to building VisionCamera in your project
Projects
None yet
Development

No branches or pull requests

5 participants