7 Replies Latest reply on Sep 23, 2016 6:23 AM by marekw29839557

    resolveLocalFileSystemURL not working on Android Nougut

    marekw29839557 Level 1

      resolveLocalFileSystemURL doesn't fire the success or fail callbacks on Android Nougut. Nothing happens!


      I had an app installed which was working fine but after the Nougut upgrade it stopped working.


      On further investigation I found that the problem is with resolveLocalFileSystemURL


      Has anybody got this to work?


      Many thanks,


        • 1. Re: resolveLocalFileSystemURL not working on Android Nougut
          simon.macdonald Adobe Employee

          What version of Cordova Android and Cordova File Plugin are you using?

          • 2. Re: resolveLocalFileSystemURL not working on Android Nougut
            marekw29839557 Level 1

            Thanks for the quick reply!


            File plugin version 4.2.0

            Phonegap build version cli-6.2.0 (6.3.0 generates a corrupt apk)




            • 3. Re: resolveLocalFileSystemURL not working on Android Nougut
              marekw29839557 Level 1

              I've tried resolving all of the cordova.file directories. Out of the following the only one that resolves is applicationDirectory and even then it returns a fail. All the others don't return success or fail. Nothing happens, no success callback of fail callback.


              Getting desperate! Hope somebody can help.


              Many thanks














              • 4. Re: resolveLocalFileSystemURL not working on Android Nougut
                VectorP Level 4

                (6.3.0 generates a corrupt apk)

                Shall we try and get this right first, then? Something else might be wrong which triggers the file problem.

                1. Can you confirm that you have both index.html and config.xml in the root of your zip file (or git repo)?

                2. Can you please post your full config.xml?

                • 5. Re: resolveLocalFileSystemURL not working on Android Nougut
                  VectorP Level 4

                  Also, a week ago the File plugin was updated. The latest version is 4.3.0, now.

                  • 6. Re: resolveLocalFileSystemURL not working on Android Nougut
                    marekw29839557 Level 1

                    Thanks for the reply.


                    I've rebuild using file api 4.3.0


                    index.html and config.xml are in the root of the zip file.


                    I had this app installed and working. I upgraded to Nougat and the app stopped working. I hadn't recompiled or reinstalled the app inbetween.


                    I set the cli to 6.3.0 and when I install the apk on my phone (Nexus 5X Nougat) I still get "The package appears to be corrupt". If I set the cli to 6.2.0 I don't get the corrupt error but I still have the resolveLocalFileSystemURL problem.


                    Here's the config.xml:


                    <?xml version="1.0" encoding="UTF-8" ?>


                            xmlns              = "http://www.w3.org/ns/widgets"

                            xmlns:gap          = "http://phonegap.com/ns/1.0"

                            xmlns:android    = "http://schemas.android.com/apk/res/android"

                            id                 = "com.marekwalford.test"

                            version            = "0.11.1"









                        <author href="https://www.test.co.uk" email="test.test@gmail.com">

                            Marek Walford



                        <platform name="android" />


                        <preference name="phonegap-version" value="cli-6.3.0" />

                        <preference name="android-minSdkVersion" value="19" />

                        <preference name="android-targetSdkVersion" value="23" />

                        <preference name="permissions" value="none"/>

                        <preference name="SplashScreen" value="screen" />

                        <preference name="SplashScreenDelay" value="1000000" />

                        <preference name="SplashMaintainAspectRatio" value="true" />

                        <preference name="AutoHideSplashScreen" value="false" />

                        <preference name="SplashScreenBackgroundColor" value="black" />

                        <preference name="FadeSplashScreen" value="false" />

                        <preference name="ShowSplashScreenSpinner" value="false" />


                        <gap:splash src="splash-portrait.png" gap:platform="android" gap:density="ldpi" gap:qualifier="port-ldpi" />

                        <gap:splash src="splash-portrait.png" gap:platform="android" gap:density="mdpi" gap:qualifier="port-mdpi" />

                        <gap:splash src="splash-portrait.png" gap:platform="android" gap:density="hdpi" gap:qualifier="port-hdpi" />

                        <gap:splash src="splash-portrait.png" gap:platform="android" gap:density="xhdpi" gap:qualifier="port-xhdpi" />

                        <gap:splash src="splash-landscape.png" gap:platform="android" gap:density="ldpi" width="320" height="200" gap:qualifier="land-ldpi" />

                        <gap:splash src="splash-landscape.png" gap:platform="android" gap:density="mdpi" width="480" height="320" gap:qualifier="land-mdpi" />

                        <gap:splash src="splash-landscape.png" gap:platform="android" gap:density="hdpi" width="800" height="480" gap:qualifier="land-hdpi" />

                        <gap:splash src="splash-landscape.png" gap:platform="android" gap:density="xhdpi" width="1280" height="720" gap:qualifier="land-xhdpi" />


                        <gap:plugin name="cordova-plugin-device" version="1.1.2" source="npm" />

                        <gap:plugin name="cordova-plugin-file" version="4.3.0" source="npm" />

                        <gap:plugin name="cordova-plugin-media" version="2.3.0" source="npm" />

                        <gap:plugin name="cordova-plugin-splashscreen" version="3.2.2" source="npm" />

                        <gap:plugin name="cordova-plugin-dialogs" version="1.2.1" source="npm" />

                        <gap:plugin name="cordova.plugins.diagnostic" version="3.0.2" source="npm" />

                        <gap:plugin name="cordova-plugin-buildinfo" version="1.1.0" source="npm" />  

                        <gap:plugin name="cordova-plugin-androidlicense" version="1.0.3" source="npm" />  

                        <gap:plugin name="cordova-plugin-spinner" version="1.1.0" source="npm" />  

                        <gap:plugin name="com.dawsonloudon.videoplayer" version="1.0.0" />

                        <gap:plugin name="com.photokandy.videothumbnail" version="1.0.1" />

                        <gap:plugin name="org.chromium.zip" version="2.1.0" />

                        <gap:plugin name="io.github.pwlin.cordova.plugins.pdialog" version="1.0.2" />


                        <icon src="icon.png" />


                    • 7. Re: resolveLocalFileSystemURL not working on Android Nougut
                      marekw29839557 Level 1

                      I've upated all of my plugins to the latest version and that solved the problem. I did check them about a week ago but didn't realise they had been updated since! I'm not sure which plugin was causing the problem.


                      Thanks very much for your help.