react-native-bluetooth-cross-platform icon indicating copy to clipboard operation
react-native-bluetooth-cross-platform copied to clipboard

Compilation Fails for RN 48 - Execution failed for task ':react-native-bluetooth-cross-platform:compileReleaseJavaWithJavac'.

Open vimalathiyagu opened this issue 7 years ago • 6 comments

RN Version - 0.48.4 The android fails to run with the below error.

/node_modules/react-native-bluetooth-cross-platform/android/src/main/java/com/rctunderdark/NetworkManagerPackage.java:25: error: method does not override or implement a method from a supertype @Override ^ 1 error :react-native-bluetooth-cross-platform:compileReleaseJavaWithJavac FAILED

FAILURE: Build failed with an exception.

  • What went wrong: Execution failed for task ':react-native-bluetooth-cross-platform:compileReleaseJavaWithJavac'.

Compilation failed; see the compiler error output for details.

In the NetworkManagerPackage.java : If we remove the @override from the below function it compiles. public List<Class<? extends JavaScriptModule>> createJSModules() { return Collections.emptyList(); }

vimalathiyagu avatar Nov 02 '17 09:11 vimalathiyagu

Stumbled on the same issue, @alexkendall please resolve

bqkhiem96 avatar Dec 06 '17 02:12 bqkhiem96

The fix was merged in #20 but probably not yet published

FlorianGerhardt avatar Jan 01 '18 13:01 FlorianGerhardt

How may I install via the #20 branch that you just showed? @FlorianGerhardt

bqkhiem96 avatar Jan 01 '18 13:01 bqkhiem96

As the branch is already in the master, you should just be able to use the repo in your package.json as shown here: https://docs.npmjs.com/files/package.json#git-urls-as-dependencies

FlorianGerhardt avatar Jan 01 '18 14:01 FlorianGerhardt

I got the above problem solved by adding the dependencies as the following image Thank you @FlorianGerhardt and of course, a new wild bug appears, should I raise another issue?

bqkhiem96 avatar Jan 01 '18 14:01 bqkhiem96

Nice :) Should probably open a new one

FlorianGerhardt avatar Jan 01 '18 15:01 FlorianGerhardt