Yes, cannot find class UIBlock when run react-native run-android
^
symbol: class UIBlock
location: package com.facebook.react.uimanager
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapView.java:105: error: getCurrentActivity()
is not public in ReactContext; cannot be accessed from outside package
if (!contextHasBug(appContext.getCurrentActivity())) {
^
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapView.java:106: error: getCurrentActivity()
is not public in ReactContext; cannot be accessed from outside package
superContext = appContext.getCurrentActivity();
^
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapView.java:109: error: cannot find symbol
if (!contextHasBug(reactContext.getCurrentActivity())) {
^
symbol: method getCurrentActivity()
location: variable reactContext of type ThemedReactContext
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapView.java:110: error: cannot find symbol
superContext = reactContext.getCurrentActivity();
^
symbol: method getCurrentActivity()
location: variable reactContext of type ThemedReactContext
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapMarkerManager.java:121: error: method does
not override or implement a method from a supertype
@Override
^
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapMarkerManager.java:124: error: cannot find
symbol
super.setZIndex(view, zIndex);
^
symbol: method setZIndex(AirMapMarker,float)
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapModule.java:89: error: cannot find symbol
uiManager.addUIBlock(new UIBlock() {
^
symbol: class UIBlock
location: class AirMapModule
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapModule.java:152: error: cannot find symbol
uiManager.addUIBlock(new UIBlock()
^
symbol: class UIBlock
location: class AirMapModule
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\AirMapModule.java:187: error: cannot find symbol
uiManager.addUIBlock(new UIBlock()
^
symbol: class UIBlock
location: class AirMapModule
C:\ReactNative\fruttineenode_modules\react-native-maps\lib\androidsrcmain\jav
a\com\airbnb\android\react\maps\RegionChangeEvent.java:15: error: no suitable co
nstructor found for Event(int)
super(id);
^
constructor Event.Event() is not applicable
(actual and formal argument lists differ in length)
constructor Event.Event(int,long) is not applicable
(actual and formal argument lists differ in length)
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
11 errors
FAILURE: Build failed with an exception.
What went wrong:
Execution failed for task ':react-native-maps: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.
Get more help at https://help.gradle.org
BUILD FAILED in 1m 12s
56 actionable tasks: 19 executed, 37 up-to-date
Yes
react-native: 0.53.2
react: 16.2.0
react-native-maps: 0.20.1
Target Platform: eg: Android 7.1.1
"react-native run-android" build success
"react-native run-android" build failed
@MatheusGit
I had the same issue when doing:
allprojects {
repositories {
mavenLocal()
jcenter()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$rootDir/../node_modules/react-native/android"
url "https://maven.google.com"
}
}
}
Splitting out the maven urls like so worked:
allprojects {
repositories {
mavenLocal()
jcenter()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$rootDir/../node_modules/react-native/android"
}
maven {
url "https://maven.google.com"
}
}
}
@MatheusGit can you please confirm and it it works close the issue?
:+1:
Most helpful comment
@MatheusGit
I had the same issue when doing:
Splitting out the maven urls like so worked: