react maps dependency issue - react-native

I am working on react native and installing
npm install react-native-maps
But i am getting error in react native cli as mentioned below
What went wrong:
A problem occurred evaluating settings 'reactmaps'.
Could not read script 'E:\react\Projects\reactmaps\reactmaps\node_modules#react-native-community\cli-platform-android\native_modules.gradle' as it does not exist.
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 1s
error Failed to install the app. Make sure you have the Android development environment set up: https://facebook.github.io/react-native/docs/getting-started.html#android-development-environment. Run CLI with --verbose flag for more details.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
FAILURE: Build failed with an exception.
Where:
Settings file 'E:\react\Projects\android\settings.gradle' line: 2
What went wrong:
A problem occurred evaluating settings 'reactmaps'.
Could not read script 'E:\react\Projects\reactmaps\reactmaps\node_modules#react-native-community\cli-platform-android\native_modules.gradle' as it does not exist.
As i installed react native cli again and again but still getting error. so what is the problem in this

Related

ReactNativeFirebase WARNING: NPM package '#react-native-firebase/auth' depends on '#react-native-firebase/app'

I downloaded a pre-made react native app I want to add features to, ran npm install and upon npx react-native run-android I receive an error related to a Firebase of which I do not know how to solve:
Task :app:processDebugResources FAILED
ReactNativeFirebase WARNING: NPM package '#react-native-firebase/auth' depends on '#react-native-firebase/app' v9.0.0 but found v8.4.7, this might cause build issues or runtime crashes.
ReactNativeFirebase WARNING: NPM package '#react-native-firebase/crashlytics' depends on '#react-native-firebase/app' v9.0.0 but found v8.4.7, this might cause build issues or runtime crashes.
FAILURE: Build failed with an exception.
What went wrong:
Execution failed for task ':app:processDebugResources'.
A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
Android resource linking failed
C:\Users\User.gradle\caches\transforms-2\files-2.1\6fece3a17ebf272ec36b2203e58d733a\core-1.7.0\res\values\values.xml:105:5-114:25: AAPT: error: resource android:attr/lStar not found.
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.
BUILD FAILED in 2m 18s
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup. Run CLI with --verbose flag for more details.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
Warning: Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01
I want install and run this pre made react native app in my android phone.

react native compiling an app from github

Helo everyone, i'm new at react native and react. I'm trying to run a project from github, I keep getting this error. I tried many solutions but still getting it.
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':react-native-push-notification:compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.
* 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 1m 11s
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup. Run CLI with --verbose flag for more details.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
Note: Some input files use or override a deprecated API.
error Command failed with exit code 1.
Taking in consediration that when I start a new project, I can run it without any problem.
Thank you

Ejected from Expo Error - SDK location not found

I am making my first react native app and I have had to eject from Expo to add in app purchases.
I have gotten the error below and not quite sure what to do when running:
react-native run-android
I have tried adding "C:\Users\Marc\AppData\Local\Android\Sdk" as PATH environmental variable but has not solved the issue
Any ideas on what to try next?
Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.3/userguide/command_line_interface.html#sec:command_line_warnings
FAILURE: Build failed with an exception.
* Where:
Build file 'C:\Users\Marc\Desktop\Swig\node_modules\react-native-reanimated\android\build.gradle' line: 89
* What went wrong:
A problem occurred configuring project ':react-native-reanimated'.
> SDK location not found. Define location with an ANDROID_SDK_ROOT environment variable or by setting the sdk.dir path in your project's local properties file at 'C:\Users\Marc\Desktop\Swig\android\local.properties'.
* 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 1m 24s
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup. Run CLI with --verbose flag for more details.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
I had added the address to the PATH variables rather then its own
https://reactnative.dev/docs/environment-setup

npx react-native run-android does not work. "java.io.IOException: The filename, directory name, or volume label syntax is incorrect"

Just recently ejected expo and I'm trying to run my app on an android device. I followed the instructions (hopefuly right) but I keep getting this error when I try to run my app:
Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.0.1/userguide/command_line_interface.html#sec:command_line_warnings
FAILURE: Build failed with an exception.
What went wrong:
A problem occurred configuring project ':app'.
java.io.IOException: The filename, directory name, or volume label syntax is incorrect
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 3s
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup. Run CLI with --verbose flag for more details.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
FAILURE: Build failed with an exception.
What went wrong:
A problem occurred configuring project ':app'.
java.io.IOException: The filename, directory name, or volume label syntax is incorrect
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 3s
at makeError (C:\Users\User\Documents\jad for eject\jad\jad\node_modules\execa\index.js:174:9)
at C:\Users\User\Documents\jad for eject\jad\jad\node_modules\execa\index.js:278:16
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async runOnAllDevices (C:\Users\User\Documents\jad for eject\jad\jad\node_modules\#react-native-community\cli-platform-android\build\commands\runAndroid\runOnAllDevices.js:94:5)
at async Command.handleAction (C:\Users\User\Documents\jad for eject\jad\jad\node_modules\#react-native-community\cli\build\index.js:186:9)
i am just using windows 7 32 bit i am also faced the same problem i solved like
you have local.properties file in your android folder or create one
in that file you have give sdk dir path like
give like this
sdk.dir=C:\\Users\\yourusername\\AppData\\Local\\Android\\Sdk
dont give like
sdk.dir=C:\Users\yourusername\AppData\Local\Android\Sdk
windows does not allow

react-native run-android doesn't build

I'm totally new in react-native and have an Android emulator running but it doesn't build react-native & shows this error...
what should i do?
FAILURE: Build failed with an exception.
What went wrong:
Could not resolve all files for configuration ':app:debugCompileClasspath'.
Could not download appcompat-v7.aar (com.android.support:appcompat-v7:28.0.0)
Could not get resource 'https://dl.google.com/dl/android/maven2/com/android/support/appcompat-v7/28.0.0/appcompat-v7-28.0.0.aar'.
Connection reset
Could not download support-fragment.aar (com.android.support:support-fragment:28.0.0)
Could not get resource
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 8m 56s
1 actionable task: 1 executed
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.bat app:installDebug. Run CLI with --verbose flag for more details.
First of all you should update your node.js
Then run the installation's cammands and for Iranian it's better to use shecan.ir before running build run-android command instead of unworking vpn.
I did these steps and the problem solved.