react-native icon indicating copy to clipboard operation
react-native copied to clipboard

Error for :org.gradle.wrapper.GradleWrapperMain

Open yipengmu opened this issue 11 years ago • 3 comments

after rebuild my whole project code struct , i saw the error below:

MyMacBook-Pro% react-native run-android JS server already running. Building and installing the app on the device (cd android && ./gradlew installDebug)... 错误: 找不到或无法加载主类[error:can't find or can't load the main calss] org.gradle.wrapper.GradleWrapperMain Could not install the app on the device, see the error above.

how solve this error ,3ks [it is not a good idea to use "gradle wrapper" ]

yipengmu avatar Oct 09 '15 13:10 yipengmu

It looks like you have a packager server running already, try to find and close the terminal window with that open :)

brentvatne avatar Oct 09 '15 16:10 brentvatne

thanks @brentvatne . after i closed and restart the nodeServer ,it works.

additional question :

if i dont want to use the commond " react-native run-android " to run the local Node Server , how can i just use android studio for two project at the same time .

because in my mind , the current react native for android is still not support two NodeServer at local dev pc ,isn't it ?

PS:our dogs both cool ~ hh

yipengmu avatar Oct 10 '15 02:10 yipengmu

Seems like the initial error was transient, closing.

Re: running two dev servers: you can run two instances of the packager on different ports, then configure your apps to load the JS bundle from the correct port. This will require changing some native code, though.

foghina avatar Oct 15 '15 15:10 foghina