flutter_beacon icon indicating copy to clipboard operation
flutter_beacon copied to clipboard

Calling initializeAndCheckScanning a second time on iOS results in a hang

Open mdanics opened this issue 4 years ago • 3 comments

I have await blutterBeacon.initializeAndCheckScanning in my main widget's initState()

On iOS (13.3) when I do a hot restart, and it reinitializes, the code hangs on the call. No errors.

Has anyone experienced this?

mdanics avatar Jul 23 '20 23:07 mdanics

Hi @mdanics

Di you already solve you problem? My iPhone 6 stuck at version 12.4, so I can't help much right now.

alann-maulana avatar Aug 10 '20 03:08 alann-maulana

I have not solved this problem. Further, if I call blutterBeacon.initializeAndCheckScanning multiple times in the app (without hot restarting) it also hangs on the second time.

I have architected the app around this limitation, and in development, I have to rebuild instead of hot restart.

mdanics avatar Aug 10 '20 04:08 mdanics

Maybe some status check for bluetooth state, location permission etc before re-calling initializeAndCheckScanning again will be helpful.

alann-maulana avatar Aug 10 '20 04:08 alann-maulana