Skip to content
This repository has been archived by the owner on Aug 11, 2020. It is now read-only.

Crash on iOS on low memory devices #304

Closed
Bouzmine opened this issue Aug 10, 2016 · 7 comments
Closed

Crash on iOS on low memory devices #304

Bouzmine opened this issue Aug 10, 2016 · 7 comments
Milestone

Comments

@Bouzmine
Copy link

The scanner crashes on low memory devices (a 5th generation iPod Touch in my case which has 512 MB of RAM). This prevents me from releasing my app (I think this is a major issue).

Citing @WebeWizard in #92 (which is now closed) :

An update from my experience.
My crashes seem to be caused by running out of memory on the device. I especially noticed the crashes on older devices. Some of these older devices only have 500MB of available ram which is easily consumed by cordova, maybe a single browser tab, and a native calendar app for example. Opening the camera + scanner plugin consumes another 100MB+.
When iOS detects you only have 50MB or so free ram, it starts killing apps to free memory for the current app. Since the current app is technically the camera now, and not the cordova app, iOS will gladly kill your app for the sake of the camera.
I hope someone else finds this useful. Learning to profile cpu/memory iOS helped a lot.

Version : 6.0.1

@lukasT
Copy link

lukasT commented Oct 20, 2016

Is this something that changed through the different versions of the scanner? I mean... did you recognize that the older versions of the plugin used less memory or is this a general problem for the scanner-plugin?

@Bouzmine
Copy link
Author

@lukasT It always crashed on those low memory devices. I started using this plugin at version 5.0.0

@EddyVerbruggen
Copy link
Collaborator

Do you still see this issue with 6.0.3? It's supposed to fix the iOS crashes.

@Purushoth-ltr
Copy link

Any updates on this issue? still persists in 6.0.3 (ipod 5th gen)

@ignacio-chiazzo
Copy link

I had the same issue. I think that the problem is related to the overload that the main thread has when the plugin runs at the first time.

I didn't find this issue #310 solved, so I changed on my own and it's still happening sometimes.

@Purushoth-ltr @EddyVerbruggen Did you find any solution?

@EddyVerbruggen
Copy link
Collaborator

EddyVerbruggen commented Dec 4, 2016

Just released 6.0.4 which has a few more memory optimizations. If I had an iPod I would have tested this. Reopen if the problems persist, but please also share ways to replicate this.

@EddyVerbruggen EddyVerbruggen added this to the 6.0.4 milestone Dec 4, 2016
@lock
Copy link

lock bot commented Jun 8, 2018

This thread has been automatically locked.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 8, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

5 participants