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 initialize class com.android.build.gradle.internal.VariantManager #24846

Closed
SantoshKumar4547 opened this issue May 14, 2019 · 5 comments
Labels
Bug Platform: Android Android applications. Stale There has been a lack of activity on this issue and it may be closed soon.

Comments

@SantoshKumar4547
Copy link

info JS server already running.
info Building and installing the app on the device (cd android && ./gradlew app:installDebug)...

FAILURE: Build failed with an exception.

  • Where:
    Build file '/Users/santoshkumar/sites/AwesomeProject/android/app/build.gradle' line: 1

  • What went wrong:
    A problem occurred evaluating project ':app'.

Could not initialize class com.android.build.gradle.internal.VariantManager

  • 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

React Native version:

info
React Native Environment Info:
System:
OS: macOS High Sierra 10.13.6
CPU: (4) x64 Intel(R) Core(TM) i5-5250U CPU @ 1.60GHz
Memory: 53.02 MB / 8.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 10.15.3 - /usr/local/bin/node
npm: 6.4.1 - /usr/local/bin/npm
SDKs:
Android SDK:
API Levels: 28
Build Tools: 28.0.3
System Images: android-28 | Google APIs Intel x86 Atom
IDEs:
Android Studio: 3.4 AI-183.5429.30.34.5452501
Xcode: /undefined - /usr/bin/xcodebuild
npmPackages:
react: 16.8.3 => 16.8.3
react-native: 0.59.8 => 0.59.8
npmGlobalPackages:
react-native-cli: 2.0.1

Steps To Reproduce

  1. while running command react-native run-android
    the system throws the above ERROR
@react-native-bot react-native-bot added the Platform: Android Android applications. label May 14, 2019
@shreyasnisal
Copy link

Could someone please help me with this issue. I am facing this and nothing has helped till now. I have tried different versions of node, npm. And also reinstalling these as well as the react-native-cli. My projects which I was able to build successfully earlier are not running either, nor are fresh projects.

@NumOne01
Copy link

NumOne01 commented Jul 12, 2019

hey could you solve it ?
if you did please share your solution.

@shreyasnisal
Copy link

No. Turns out that I had to make a lot of changes to my OS, and when I ran it again, it was working fine. I don't think this would solve the error, but are you using a windows machine with spaces in your user account name?

@stale
Copy link

stale bot commented Oct 10, 2019

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Oct 10, 2019
@stale
Copy link

stale bot commented Oct 17, 2019

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information.

@stale stale bot closed this as completed Oct 17, 2019
@facebook facebook locked as resolved and limited conversation to collaborators Oct 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Platform: Android Android applications. Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

No branches or pull requests

4 participants