Eugene B
unread,Sep 26, 2025, 12:37:41 PM (yesterday) Sep 26Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Android CameraX Discussion Group
Hi,
We are experiencing a regression in the CameraState observation behavior when upgrading from CameraX 1.5.0-alpha04 to the stable 1.5.0 release.
In our application, we observe the camera's state to track its lifecycle. The following code worked as expected in version 1.5.0-alpha04:
cameraState?.observe(lifecycleOwner) { state ->
Log.d(TAG, "Camera state = $state")
// Handle state changing
}
Previous Behavior (1.5.0-alpha04):
The state flow consistently transitioned through CLOSED -> OPENING -> OPEN when the camera was successfully opened.
Current Behavior (1.5.0):
The state now often gets stuck at OPENING. The OPEN state is rarely emitted, even though the camera is fully functional (a preview stream is active, and capture sessions work correctly). This breaks our logic that relies on confirming the camera is fully open.
Question:
Is this a known issue in the stable 1.5.0 release?
If so, is there a known workaround to reliably get the OPEN state event?