EddyVerbruggen / nativescript-plugin-firebase

:fire: NativeScript plugin for Firebase
https://firebase.google.com
MIT License
1.01k stars 448 forks source link

Storage downloadFile works in iOS 13, not in iOS 14 #1782

Open nmandyam opened 3 years ago

nmandyam commented 3 years ago

I'm running tns-ios 6.5.4 (not 7.x), Xcode 11.7. The downloadFile API works fine on iOS devices running 13.x or lesser, fails on 14.x. I can't run debug - or even console.log - to figure out the exact failure because Xcode 11.7 does not connect to devices running 14.x. And neither does NS 6.5.4 - it fails to install the app on the iOS 14.4 device. But I do know the downloadFile is NOT working on iOS 14.4 devices, based on the behaviour of the app. Any suggestions on what I can do to get past this? Is there, for example, an info.plist permission or something that I can set up?

Here's the code:

logoPath = documents.path + "/files/menu_icon.png"; remote_path = '<my remote location>' + '/menu_icon.png'; var t1 = await firebase.storage.downloadFile({ remoteFullPath: remote_path, localFullPath: logoPath }) .catch(err => { console.log("error getting file: " + remote_path); return ( {err: err} ); });

Any help appreciated!

nmandyam commented 3 years ago

This does not seem to be a Storage issue, sorry! But it IS strange behaviour, even with Xcode 12: theme-change works OK on the Simulator, works OK when deployed to a 14.4 device via Xcode, fails when delivered via TestFlight. Anyway, closing this issue, since this has nothing to with the downloadFile API.

nmandyam commented 3 years ago

Sorry to go back and forth on this, but after more instrumentation, it is clear that this IS an issue with the download. The downloadFile API fails with the error "An unknown error occurred, please check the server response." Here's someone using Flutter with an identical error and behaviour (last item on page): https://github.com/FirebaseExtended/flutterfire/issues/3791 Any ideas on how I can solve this?