quaggaJS icon indicating copy to clipboard operation
quaggaJS copied to clipboard

LiveStream crash after a certain period (10 sec - several minutes)

Open DeanClaes opened this issue 8 years ago • 7 comments

I have been experiencing crashes on my Android phone (running in Chrome, tested on 2 seperate devices) whilst running the livestream example on the quaggaJS-site.

If I just leave my phone on the table for about one minute it would crash the page. It seems to crash sooner if the livestream is totally black (camera placed against the table). I suspect that it keeps using up more memory and then eventually crashes.

Black livestream : about 30s Mixed livestream: up to five minutes

DeanClaes avatar Oct 20 '16 09:10 DeanClaes

I too experience this occasionally. It's weird how it's triggered, because it works longer the more processing actions are done without a detection. I did some investigating of the memory space and it looks like there might be a leak in the frame buffer. I'm getting hounded to release so I can't dive into profiling it right now, but it definitely causes issues such as crashing to the launcher on Firefox mobile.

eight-molecules avatar Dec 06 '16 17:12 eight-molecules

hey @gelliott181 , even i experienced the chrome crash after running the scanner continuously for few minutes, looks to me like this is not sporadic. so have you had any break-through on this issue ?

dreamweiver avatar Jan 23 '17 09:01 dreamweiver

Yeah, I'm aware that the default configuration is not optimal for running on mobile devices. With the next release I'll be reducing the frequency configuration to 5 frames per second, and numOfWorkers to 2 which, both, is still sufficient for the 99% case. Could you try if those settings would also make sense for you?

serratus avatar Mar 31 '17 12:03 serratus

Hey @serratus , i havent tried with reduced frequecny, but i did try with lesser workers process and the result was still the same. When i posted my previous comment i was working on prototype which would make use of your barcode scanner, but now that project is suspended, so i dont think i would be able to test with the sample config what your have provided.

dreamweiver avatar Apr 15 '17 07:04 dreamweiver

Anyone still having issues with this? I don't believe I've seen it, and I've left quagga open for quite a while on my phone.

ericblade avatar Jun 08 '18 06:06 ericblade

@ericblade Im getting this on an old android tablet with chrome. If I open scanner with it pointed at a barcode its fine. If I waive it around the room it crashes in 3-5seconds. I paused the debugger at onProcessed and the camera stayed open indefinitely.

ryanmagits avatar Apr 13 '20 21:04 ryanmagits

@ryanmagits hmm. how old is old? i wonder if it's just something that may not be fixable in older chrome implementations .. might try my fork of the lib, https://github.com/ericblade/quagga2 and see if it still does it there?

ericblade avatar Apr 14 '20 09:04 ericblade