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

RN 0.60.5 - err: method does not override @Override #87

Open
oleksandr-sokolov opened this issue Sep 16, 2019 · 1 comment
Open

RN 0.60.5 - err: method does not override @Override #87

oleksandr-sokolov opened this issue Sep 16, 2019 · 1 comment

Comments

@oleksandr-sokolov
Copy link

if I try to comment this line (with @OverRide) - can run the app, but get another error: CustomKeyboardViewNative was not found in the UIManager.

BUILD FAILED in 7s

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 app:installDebug -PreactNativeDevServerPort=8081
/node_modules/react-native-keyboard-input/lib/android/src/main/java/com/wix/reactnativekeyboardinput/CustomKeyboardRootViewShadow.java:16: error: method does not override or implement a method from a supertype
    @Override
    ^
1 error

FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':reactnativekeyboardinput:compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.

* Get more help at https://help.gradle.org

settings.gradle:

include ':reactnativekeyboardinput'
project(':reactnativekeyboardinput').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-keyboard-input/lib/android')

build.gradle:

dependencies {
    implementation project(':react-native-video')
    implementation project(':react-native-pdf')
    implementation project(':rn-fetch-blob')
    compile project(":reactnativekeyboardinput")
    implementation project(':@react-native-community_async-storage')
    implementation project(':react-native-vector-icons')
    implementation project(':react-native-reanimated')
    implementation project(':react-native-gesture-handler')
    implementation project(':react-native-view-pdf')
    implementation project(':react-native-orientation')
    implementation project(':react-native-bluetooth-info')
    implementation project(':react-native-device-info')
    implementation project(':react-native-community-netinfo')
    implementation ("com.google.android.gms:play-services-vision:18.0.0") {
        force = true;
    }
    implementation fileTree(dir: "libs", include: ["*.jar"])
    implementation "com.android.support:appcompat-v7:28"
    implementation 'com.android.support:support-annotations:28'
    implementation "androidx.appcompat:appcompat:1.0.2"
    implementation 'androidx.annotation:annotation:1.0.2'
    implementation "com.facebook.react:react-native:+"  // From node_modules

    if (enableHermes) {
      def hermesPath = "../../node_modules/hermesvm/android/";
      debugImplementation files(hermesPath + "hermes-debug.aar")
      releaseImplementation files(hermesPath + "hermes-release.aar")
    } else {
      implementation jscFlavor
    }

    implementation 'pl.droidsonroids.gif:android-gif-drawable:1.2.10'
    implementation 'com.facebook.fresco:animated-gif:1.3.0'
}
@xz551
Copy link

xz551 commented Sep 29, 2019

delete
import android.support.annotation.NonNull;
add
import androidx.annotation.NonNull;

fiels
CustomKeyboardRootView.java

ReactSoftKeyboardMonitor.java

because RN6.0 used androidx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants