How native react works on Android

React native: Android project not found. Maybe run responsive Android first?


I had a problem in my React Native project that used to work fine but suddenly stopped working. Whenever I used the command:

I have a I received an error message :

Android project not found. Maybe run responsive Android first?

I have tries to to run:

But it said:

After trying:

The error returned was:

Search folders for symlinks in D: \ ProjectRoot \ ReactNativeProjects \ AwesomeProject \ node_modules (48 ms) The app must be defined in the configuration file to define the project name. It cannot contain spaces or hyphens.

This is the app.json file:



Reply:


I raised this question and answered myself as I thought it would help others who are facing similar problems. I had a hard time figuring out the real reason for this as the error shown in the terminal was not accurate.

To fix the problem, please update the responsive package.

  1. Go to Project master .

  2. Update the native React package in the Command prompt, by The following enter:

    .

  3. Then accept to update all files by editing the command prompt enter .

Reference: https://github.com/facebook/react-native/issues/9312







I know it's an old question, but one of these solutions didn't work for me, and maybe there are others like me. I already solved my problem running this command






Open your React Native Project root directory and find Android -> App -> Build -> Intermediates -> Signing_Config -> Debug -> Out -> Signing-Config.json. Delete the signing-config.json file. Try it again

Or

1) Sometimes when we have an older version of React Native and some newly installed packages don't support older versions. You then need to upgrade the native React project using the react-native upgrade command.

  1. After updating the current project to a new version, this error should be resolved.

Make sure you start the project with the (non-expo) command:

If there is a folder, do the following:

responsive ejection


In the latest version of react-native, this suggestion comes when you try to issue the following command:

Search folders for symlinks in D: \ ProjectRoot \ ReactNativeProjects \ AwesomeProject \ node_modules (48 ms) The app must be defined in the configuration file to define the project name. It cannot contain spaces or hyphens.

Now when you enter the following command:

The following is displayed:

Browsing folders for symlinks in D: \ ProjectRoot \ ReactNativeProjects \ AwesomeProject \ node_modules (56 ms) You should consider using the new Git-based upgrade tool. It makes upgrades easier by automatically resolving most conflicts. How to use it: - Revert to the old version of React Native. - Run "npm install -g react-native-git-upgrade". - Run "react-native-git-upgrade". See https://facebook.github.io /react-native/docs/upgrading.html The reaction-native version in "package.json" does not match the installed version in "node_modules". Try running "npm install" to fix this. Cancellation.

There is a clear solution in the responsive Facebook command suggestions.

These commands check the current version and whether or not an update is required.

Another solution:

React-Native: Command not recognized. Possibly caused by npm install

Please also note:

Solution to "Expo: Module LogReporter cannot be found"



I liked that ... it worked !!

  1. Introduce in the CMD project master responsive upgrade .
  2. If you are still having problems put you for sure that in the dependencies json in package.json is responsive , and add it if not
  3. If you continue to have problems, get the version of react native in cmd react-native -v and check that the value returned in cmd and package.json are the same. Update the package.json file with the value returned in cmd

Here my problem is solved.


We encountered this problem because files were from Android folder gradlew and gradlew.bat (Gradle- Start script for UN * X or Windows) somehow got into the global .gitignore file and were therefore not displayed in local environments.

Indeed, a responsive upgrade performed Run command will restore these files, which will resolve the problem.


If the react-native command is not found, you should install the reactive-native CLI as a supplement:

Then you can follow the steps above.

Further details: react-native: command not found


Open the command prompt as administrator and go to the project folder. Run android (npx react-native run-android).


When you started your project like this

After that, you can question the above mentioned problem. So the solution is:


Here app.json has no name, but an expo-related configuration. Just add name and display name fields in app.json.

app.json (first two lines):

After that, just do the following:

$ React-Native Eject

info Generate the iOS folder.

info Generate the Android folder.

No responsive upgrade required.



Remove the file: Respond to the native project root directory and search for Android -> App -> Build -> Intermediates -> Signing_Config -> Debug -> Out -> Signing-Config.json.


Running Terminal as an administrator in Windows did the trick for me ... Other solutions didn't work.



I am using Android Studio (non-Expo) and this works for me


You need to run your cmd with administrator rights. That solved the same problem for me. Didn't "eject" or do anything else.



Open your React Native Project root directory and search for Android -> App -> Build -> Intermediates -> Signing_Config -> Debug -> Out -> Signing-Config.json

Delete the file and try again.


I faced this problem today and none of the solutions worked for me so I found another one.

A poorly formatted AndroidManifest.xml causes this problem . Perhaps you set the splash screen like today and did not format AndroidManifest properly


My working solution is below, none of the above worked for me:

CD into your project folder and enter expo start --android.

Or the long way:

  1. Open the AVD manager in Android Studio and run a virtual device (you can then close AS).
  2. CMD into your project folder and enter 'expo start'
  3. Once the expo starts, choose option 2: "Press One for Android Emulator".

It will install expo on the virtual device and you can test from there


When I ran I got this error:

  • Delete the folder.
  • Run This generated the folder

  • Then run to build Android


You should consider using the new upgrade tool which is based on Git. It makes upgrades easier by automatically resolving most conflicts. How to use it: - Revert to the old version of React Native. - Run "npm install -g react-native-git-upgrade". - Run "react-native-git-upgrade". See https://facebook.github.io /react-native/docs/upgrading.html


When you have created your project with the command like, you must then eject your project:

By then, when you've built your project, you'll need to use it



Maybe it's too late, I replaced the folder from a backup file. It worked for me.


I solved the problem by exiting all instances of java.exe with:



I had the same bug in a project (created with React Native CLI):

It turned out that I had a syntax error in my Android manifest file (android / app / src / main / AndroidManifest.xml).


In my case, I forgot to add sudo. Fixed as follows:

We use cookies and other tracking technologies to improve your browsing experience on our website, to show you personalized content and targeted ads, to analyze our website traffic, and to understand where our visitors are coming from.

By continuing, you consent to our use of cookies and other tracking technologies and affirm you're at least 16 years old or have consent from a parent or guardian.

You can read details in our Cookie policy and Privacy policy.