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

Couldn't find meta-data for provider with authority ${applicationId}.fileprovider #622

Open
littlesalt opened this issue Dec 13, 2019 · 2 comments

Comments

@littlesalt
Copy link

java.lang.IllegalArgumentException: Couldn't find meta-data for provider with authority ${applicationId}.fileprovider
W/System.err(32195): at androidx.core.content.FileProvider.parsePathStrategy(FileProvider.java:606)
W/System.err(32195): at androidx.core.content.FileProvider.getPathStrategy(FileProvider.java:579)
W/System.err(32195): at androidx.core.content.FileProvider.getUriForFile(FileProvider.java:417)
W/System.err(32195): at com.flutter_webview_plugin.WebviewManager.getOutputFilename(WebviewManager.java:290)
W/System.err(32195): at com.flutter_webview_plugin.WebviewManager.access$900(WebviewManager.java:47)
W/System.err(32195): at com.flutter_webview_plugin.WebviewManager$4.onShowFileChooser(WebviewManager.java:227)
W/System.err(32195): at com.android.webview.chromium.WebViewContentsClientAdapter.showFileChooser(WebViewContentsClientAdapter.java:1091)
W/System.err(32195): at org.chromium.android_webview.AwWebContentsDelegateAdapter.runFileChooser(AwWebContentsDelegateAdapter.java:227)
W/System.err(32195): at org.chromium.base.SystemMessageHandler.nativeDoRunLoopOnce(Native Method)
W/System.err(32195): at org.chromium.base.SystemMessageHandler.handleMessage(SystemMessageHandler.java:41)
W/System.err(32195): at android.os.Handler.dispatchMessage(Handler.java:105)
W/System.err(32195): at android.os.Looper.loop(Looper.java:156)
W/System.err(32195): at android.app.ActivityThread.main(ActivityThread.java:6517)
W/System.err(32195): at java.lang.reflect.Method.invoke(Native Method)
W/System.err(32195): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:942)
W/System.err(32195): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:832)
F/chromium(32195): [FATAL:jni_android.cc(243)] Please include Java exception stack in crash report
W/google-breakpad(32195): ### ### ### ### ### ### ### ### ### ### ### ### ###
W/google-breakpad(32195): Chrome build fingerprint:
W/google-breakpad(32195): 0.0.2
W/google-breakpad(32195): 1
W/google-breakpad(32195): ### ### ### ### ### ### ### ### ### ### ### ### ###
F/libc (32195): Fatal signal 6 (SIGABRT), code -6 in tid 32195 (m.*.rock)


Build fingerprint: 'HUAWEI/MLA-AL10/HWMLA:7.0/HUAWEIMLA-AL10/C00B364:user/release-keys'
Revision: '0'
ABI: 'arm64'
pid: 32195, tid: 32195, name: m..rock >>> com..rock <<<
signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
Abort message: '[FATAL:jni_android.cc(243)] Please include Java exception stack in crash report
'
x0 0000000000000000 x1 0000000000007dc3 x2 0000000000000006 x3 0000000000000008
x4 0000007fd4b4a36c x5 0000000000000009 x6 0000000000000009 x7 0000007f7f8a5ca3
x8 0000000000000083 x9 ffffffffffffffdf x10 0000000000000000 x11 0000000000000001
x12 ffffffffffffffff x13 0000000000000054 x14 0000007f7f8a5c98 x15 003c39407cc683a3
x16 0000007f97447ec8 x17 0000007f973f0c38 x18 0000000072334eb8 x19 0000007f991ebb40
x20 0000000000000006 x21 0000007f991eba98 x22 0000000000000002 x23 0000000000000000
x24 0000007fd4b4ac10 x25 0000007fd4b4ae20 x26 0000007fd4b4ae40 x27 000000000010001d
x28 0000000000000001 x29 0000007fd4b4a6b0 x30 0000007f973ee0e0
sp 0000007fd4b4a690 pc 0000007f973f0c40 pstate 0000000060000000
backtrace:
#00 pc 000000000006bc40 /system/lib64/libc.so (tgkill+8)
#1 pc 00000000000690dc /system/lib64/libc.so (pthread_kill+64)
#2 pc 0000000000023e68 /system/lib64/libc.so (raise+24)
#3 pc 000000000001c8ec /system/lib64/libc.so (abort+52)
#4 pc 00000000007624d4 /system/lib64/libwebviewchromium.so
Lost connection to device.

@littlesalt
Copy link
Author

littlesalt commented Dec 13, 2019

part of AndroidManifest.xml:
<provider android:name="sk.fourq.otaupdate.OtaUpdateFileProvider" android:authorities="${applicationId}.ota_update_provider" android:exported="false" android:grantUriPermissions="true"> <meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/filepaths" /> </provider> <provider android:name="androidx.core.content.FileProvider" android:authorities="${applicationId}.fileProvider" android:exported="false" android:grantUriPermissions="true" tools:replace="android:authorities"> <meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/filepaths" tools:replace="android:resource" /> </provider>
filepaths.xml:
<?xml version="1.0" encoding="utf-8"?> <paths xmlns:android="http://schemas.android.com/apk/res/android"> <external-path name="external_download" path="Download"/> <root-path name="root_path" path="." /> </paths>

@lanzhu1993
Copy link

lanzhu1993 commented Jan 8, 2020

<provider android:name="androidx.core.content.FileProvider" android:authorities="${applicationId}.fileprovider" android:exported="false" android:grantUriPermissions="true" tools:replace="android:authorities"> <meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/file_paths" tools:replace="android:resource" /> </provider>

file_path.xml

`

<!-- /storage/emulated/0/Download/com.bugly.upgrade.demo/.beta/apk-->
<external-path name="beta_external_path" path="Download/"/>
<!--/storage/emulated/0/Android/data/com.bugly.upgrade.demo/files/apk/-->
<external-path name="beta_external_files_path" path="Android/data/"/>


<external-cache-path
    name="external-cache-path"
    path="."/>
<external-files-path
    name="external-files-path"
    path="."/>
<files-path
    name="files_path"
    path="."/>
<cache-path
    name="cache-path"
    path="."/>
<root-path
    name="name"
    path="."/>
`

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