flutter_full_pdf_viewer
flutter_full_pdf_viewer copied to clipboard
No implementation found
I was working before, I don't know why it dosen't now?
I get this error on console, the problem is only Anroid related:
No implementation found for long com.shockwave.pdfium.PdfiumCore.nativeOpenDocument(int, java.lang.String) (tried Java_com_shockwave_pdfium_PdfiumCore_nativeOpenDocument and Java_com_shockwave_pdfium_PdfiumCore_nativeOpenDocument__ILjava_lang_String_2)
Thank so much!
I also encounter the same issue. Perhaps, the title should be Native libraries failed to load: couldn't find "libmodpng.so".
The library was working fine on dev channel 1.16.4-pre83.
Now it fails on later dev versions as 1.16.4-pre83 is no longer there, and also fails on 1.17.1 channel stable:
Flutter 1.17.1 • channel stable • https://github.com/flutter/flutter.git
Framework • revision f7a6a7906b (6 days ago) • 2020-05-12 18:39:00 -0700
Engine • revision 6bc433c6b6
Tools • Dart 2.8.2
E/com.shockwave.pdfium.PdfiumCore( 8159): Native libraries failed to load - java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/[appPackageNameCode]/base.apk"],nativeLibraryDirectories=[/data/app/[appPackageNameCode]/lib/arm64, /data/app/[appPackageNameCode]/base.apk!/lib/arm64-v8a, /system/lib64, /system/vendor/lib64]]] couldn't find "libmodpng.so"
W/ps.app_name( 8159): Accessing hidden field Ljava/io/FileDescriptor;->descriptor:I (light greylist, reflection)
E/ps.app_name( 8159): No implementation found for long com.shockwave.pdfium.PdfiumCore.nativeOpenDocument(int, java.lang.String) (tried Java_com_shockwave_pdfium_PdfiumCore_nativeOpenDocument and Java_com_shockwave_pdfium_PdfiumCore_nativeOpenDocument__ILjava_lang_String_2)
E/PDFView ( 8159): load pdf error
E/PDFView ( 8159): java.lang.UnsatisfiedLinkError: No implementation found for long com.shockwave.pdfium.PdfiumCore.nativeOpenDocument(int, java.lang.String) (tried Java_com_shockwave_pdfium_PdfiumCore_nativeOpenDocument and Java_com_shockwave_pdfium_PdfiumCore_nativeOpenDocument__ILjava_lang_String_2)
E/PDFView ( 8159): at com.shockwave.pdfium.PdfiumCore.nativeOpenDocument(Native Method)
E/PDFView ( 8159): at com.shockwave.pdfium.PdfiumCore.newDocument(PdfiumCore.java:113)
E/PDFView ( 8159): at com.github.barteksc.pdfviewer.source.FileSource.createDocument(FileSource.java:38)
E/PDFView ( 8159): at com.github.barteksc.pdfviewer.DecodingAsyncTask.doInBackground(DecodingAsyncTask.java:53)
E/PDFView ( 8159): at com.github.barteksc.pdfviewer.DecodingAsyncTask.doInBackground(DecodingAsyncTask.java:25)
E/PDFView ( 8159): at android.os.AsyncTask$2.call(AsyncTask.java:333)
E/PDFView ( 8159): at java.util.concurrent.FutureTask.run(FutureTask.java:266)
E/PDFView ( 8159): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
E/PDFView ( 8159): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
E/PDFView ( 8159): at java.lang.Thread.run(Thread.java:764)
W/System ( 8159): A resource failed to call close.
Same in my app.
I had the same problem. To fix this remove
minifyEnabled true
from the release config inside the buildTypes of android/app/gradle.build.
That's great news @thomas4Bitcraft!! as soon as I can I will try, Thank so much for share.
Sadly still with the same problem. Removing minifyEnabled true, didn't make it work.
For me solved as following:
- Removed the app from the device.
-
flutter clean
- Re-installed the app.
I have this problem Too.
Flutter: 1.17.5
Runing in debug mode or release mode.
Both doesnt show the pdf file.
E/com.shockwave.pdfium.PdfiumCore(28515): Native libraries failed to load - java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/****-TaiWevzo7au7sddeIqZynw==/base.apk"],nativeLibraryDirectories=[/data/app/****-TaiWevzo7au7sddeIqZynw==/lib/arm64, /data/app/****-TaiWevzo7au7sddeIqZynw==/base.apk!/lib/arm64-v8a, /system/lib64, /system/vendor/lib64]]] couldn't find "**libmodpng**.so"
I was working before, I don't know why it dosen't now?
I get this error on console, the problem is only Anroid related:
No implementation found for long com.shockwave.pdfium.PdfiumCore.nativeOpenDocument(int, java.lang.String) (tried Java_com_shockwave_pdfium_PdfiumCore_nativeOpenDocument and Java_com_shockwave_pdfium_PdfiumCore_nativeOpenDocument__ILjava_lang_String_2)
Thank so much!
Any news about this? ...
Do you resolved this error? I have the same problem ;(
flutter clean
THANKS @Fhyrel I RESOLVED WHITH FLUTTER CLEAN TOO!
Run: flutter pub add pdfx
The issue will be resolved as it adds all of the missing library and build correctly.
reference: https://github.com/syncfusion/flutter-widgets/issues/677#issuecomment-1099531436