tazik561 / FlutterMp3FinderPlugin

BSD 3-Clause "New" or "Revised" License
1 stars 1 forks source link

I used your plugin but it threw me some error #2

Open Tushargupta9800 opened 4 years ago

Tushargupta9800 commented 4 years ago

When i run the app on my phone it threw me the following error

C:\Users\91895\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flute_music_player-0.0.6\android\src\main\java\com\mtechviral\musicfinder\MusicHelper.java:8: error: cannot find symbol import android.support.v4.app.ActivityCompat; ^ symbol: class ActivityCompat location: package android.support.v4.app C:\Users\91895\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flute_music_player-0.0.6\android\src\main\java\com\mtechviral\musicfinder\MusicHelper.java:9: error: package android.support.v4.content does not exist import android.support.v4.content.ContextCompat; ^ C:\Users\91895\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flute_music_player-0.0.6\android\src\main\java\com\mtechviral\musicfinder\MusicHelper.java:10: error: package android.support.v7.app does not exist import android.support.v7.app.AppCompatActivity; ^ C:\Users\91895\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flute_music_player-0.0.6\android\src\main\java\com\mtechviral\musicfinder\MusicHelper.java:15: error: cannot find symbol public static boolean hasExternalStorageAccess(AppCompatActivity activity) { ^ symbol: class AppCompatActivity location: class MusicHelper C:\Users\91895\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flute_music_player-0.0.6\android\src\main\java\com\mtechviral\musicfinder\MusicHelper.java:16: error: cannot find symbol if(ContextCompat.checkSelfPermission(activity, Manifest.permission.READ_EXTERNAL_STORAGE) ^ symbol: variable ContextCompat location: class MusicHelper C:\Users\91895\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flute_music_player-0.0.6\android\src\main\java\com\mtechviral\musicfinder\MusicHelper.java:19: error: cannot find symbol ActivityCompat.requestPermissions(activity, ^ symbol: variable ActivityCompat location: class MusicHelper Note: C:\Users\91895\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flute_music_player-0.0.6\android\src\main\java\com\mtechviral\musicfinder\MusicFinderPlugin.java uses or overrides a deprecated API. Note: Recompile with -Xlint:deprecation for details. Note: C:\Users\91895\AppData\Local\Pub\Cache\hosted\pub.dartlang.org\flute_music_player-0.0.6\android\src\main\java\com\mtechviral\musicfinder\MusicFinderPlugin.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details. 6 errors

FAILURE: Build failed with an exception.

BUILD FAILED in 52s The built failed likely due to AndroidX incompatibilities in a plugin. The tool is about to try using Jetfier to solve the incompatibility. Building plugin audioplayers... Running Gradle task 'assembleAarRelease'...

Exception in thread "main" java.util.zip.ZipException: error in opening zip file at java.util.zip.ZipFile.open(Native Method) at java.util.zip.ZipFile.(ZipFile.java:225) at java.util.zip.ZipFile.(ZipFile.java:155) at java.util.zip.ZipFile.(ZipFile.java:169) at org.gradle.wrapper.Install.unzip(Install.java:214) at org.gradle.wrapper.Install.access$600(Install.java:27) at org.gradle.wrapper.Install$1.call(Install.java:74) at org.gradle.wrapper.Install$1.call(Install.java:48) at org.gradle.wrapper.ExclusiveFileAccessManager.access(ExclusiveFileAccessManager.java:65) at org.gradle.wrapper.Install.createDist(Install.java:48) at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:128) at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:61)

Exception: The plugin audioplayers could not be built due to the issue above.

Please help me with it, thanks in advance.

Tushargupta9800 commented 4 years ago

I tried your plugin again but this time it shows me another error.

MissingPluginException(No implementation found for method scanDeviceForMp3Files on channel flutter_mp3_finder)

Please help! waiting for your reply.

tazik561 commented 4 years ago

Thanks for opening issue. I check library but i do not get problem so please open your android folder with android studio and let to android studio to sync gradle.