-
Notifications
You must be signed in to change notification settings - Fork 314
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
Upload failed if app is running in the background in React Native #179
Comments
Please provide more details to allow us to reproduce this. However, AFAIK, iOS does not allow arbitrary background activities so it's possible that there is nothing we can do if iOS decides to kill your app if it is put into background. |
@iqbalfaisal A screenshot is not sufficient to allow us to reproduce this. Please provide the minimal code and instructions so we can trigger the same error. |
@Acconut this error will trigger when the picture is uploading and App goes to background and came back in IOS |
@Acconut sorry i forgot to mention. App should be in release mode on real device rather than emulator |
I personally don't have an iOS device or emulator available, so I cannot debug this. Maybe @ifedapoolarewaju could help or you, @iqbalfaisal, might be able to take a look on your own. |
@Acconut i tried but failed. Kindly solved this because my app is delaying due to this problem |
It's unfortunate that your app is delayed. If it's very urgent for you, we can talk about private paid support. |
@ifedapoolarewaju are you there? |
Yes @iqbalfaisal you're right. I'm facing the same error. Let me know when you find something useful. I think core contributor is not serious about the library. |
That's not a very nice claim about the work that we put into this open source project and provide to you free of any charge. You should know that background uploads on iOS is not something we do not care about but even our native Objective-C SDK cannot do, because iOS simply doesn't allow it. I don't want to go into details but instead refer you to tus/TUSKit#57 where you can read more. So we are inherently limited in what we can do. |
I know @Acconut. I really appreciate your time and effort also your team.
Yes i had read this but question is why App is crashing. I Know Apple not allow background processes but Tus-Client should send error in OnError function or just stop uploading without crashing the whole App. I hope you understand my point. Thanks |
Really sorry if you hurt @Acconut |
Thanks for the kind words and the explanation, @iqbalfaisal. If I understand it now correctly, there are two problems:
Problem 1 cannot be solved directly since it's a restricting from iOS (unless you use the location hack as in tus/TUSKit#57). Problem 2 should be solvable but I can't work on it personal because I don't have access to an iOS device or emulator. So help is in this regard greatly appreciated if you want to see this problem fixed. |
Yes @Acconut i'm talking about this problem. I have spent whole day to sort out this problem but unfortunately i have failed and frustrated. I have put this problem in future TODO list and going to release the my App. Thanks for the giving me yours important time. |
@iqbalfaisal the issue is not related to tus-js-client. Instead, it is caused by a bug in core react-native. You can view the details and solution here. |
@iqbalfaisal Thank you for the info. If I read it correctly, this fix was not yet included in any release, but will make it into 0.72.0? reactwg/react-native-releases#54 |
Describe the bug
Upload failed if app is running in the background in React Native. Specially in IOS
Setup details
Please provide following details, if applicable to your situation:
The text was updated successfully, but these errors were encountered: