2

I am using react-native 0.57.1 react-native track player 0.2.5 I have got following error:

C:\zzzprojects\app\node_modules\react-native-track-player\android\src\main\java\guichaguri\trackplayer\metadata\Metadata.java:9: error: package android.support.v4.media does not exist import android.support.v4.media.MediaMetadataCompat;

^ C:\zzzprojects\app\node_modules\react-native-track-player\android\src\main\java\guichaguri\trackplayer\metadata\Metadata.java:10: error: package android.support.v4.media does not exist import android.support.v4.media.RatingCompat;

^ C:\zzzprojects\app\node_modules\react-native-track-player\android\src\main\java\guichaguri\trackplayer\metadata\Metadata.java:11: error: package android.support.v4.media.session does not exist import android.support.v4.media.session.MediaButtonReceiver;

^ C:\zzzprojects\app\node_modules\react-native-track-player\android\src\main\java\guichaguri\trackplayer\metadata\Metadata.java:12: error: package android.support.v4.media.session does not exist import android.support.v4.media.session.MediaControllerCompat;

^ ........... ........... ..........

C:\zzzprojects\app\node_modules\react-native-track-player\android\src\main\java\guichaguri\trackplayer\metadata\components\CustomVolume.java:14: error: cannot find symbol super(canControl ? VOLUME_CONTROL_ABSOLUTE : VOLUME_CONTROL_FIXED, maxVolume, (int)(volume * maxVolume));

^ symbol: variable VOLUME_CONTROL_ABSOLUTE location: class CustomVolume Note: Some input files use unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. Note: Some messages have been simplified; recompile with -Xdiags:verbose to get full output 100 errors

FAILURE: Build failed with an exception.

What went wrong:

Execution failed for task ':react-native-track-player: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. Run with --scan to get full insights.

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

BUILD FAILED in 43s 36 actionable tasks: 25 executed, 11 up-to-date Could not install the app on the device, read the error above for details. Make sure you have an Android emulator running or a device connected and have set up your Android development environment:

https://facebook.github.io/react-native/docs/getting-started.html

I have tried a lot of methods I even init a new project and just install react native it is giving same error again . ... thanks. do answer me soon

Haider Ali
  • 1,125
  • 5
  • 20
  • thanks @rajanmishra can you help with issue too.i have raised issue but they dont seem to bother......https://github.com/react-native-kit/react-native-track-player/issues/301 – KRISHNA YADAV Oct 17 '18 at 05:07

0 Answers0