-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
🐛 App unable to go to sleep once camera loads #3041
Comments
Guten Tag, Hans here. Note New features, bugfixes, updates and other improvements are all handled mostly by |
@FoundersApproach We're seeing a similar issue on iOS 16+. On iOS <= 15 the green dot showing the camera is active never goes away. Can you try capturing the "goBack" and then using setTimeout to set the camera in-active prior to going back? Something like this:
Note: Would need to disable back gestures in order to make sure navigating back is always captured. |
Looks like this specific line keeps the phone from going to sleep. It doesn't appear that this is implemented on Android for VC. |
Perhaps this should just be removed? Idle management could be left to library consumers. This would benefit Expo users, especially, which uses |
What's happening?
Once camera library loads in one screen and going back to previous screen in stack navigation then app unable to goes to sleep. May be camera reference object is unable to let app sleep ?
I did some object reference clearance in component unmount but no luck. Please help!
Reproduceable Code
Relevant log output
Camera Device
Device
iPhone 14 plus (ios 17.1.1)
VisionCamera Version
"react-native-vision-camera": "^3.9.2"
Can you reproduce this issue in the VisionCamera Example app?
Yes, I can reproduce the same issue in the Example app here
Additional information
The text was updated successfully, but these errors were encountered: