[codex] Fix Android camera snap cleanup#98040
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed July 2, 2026, 8:08 AM ET / 12:08 UTC. Summary PR surface: Other +6. Total +6 across 1 file. Reproducibility: yes. at source level: current main binds Review metrics: none identified. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Security Review detailsBest possible solution: Merge only after redacted real Android after-fix proof for the scoped Do we have a high-confidence way to reproduce the issue? Yes at source level: current main binds Is this the best way to solve the issue? Yes, this appears to be the best narrow code shape: unbind the exact AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 4f933ccf7b62. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Other +6. Total +6 across 1 file. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
0d31970 to
8bf6682
Compare
|
Maintainer live proof — exact head The scoped fix now unbinds the invocation-owned Before / after: successful
|
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
Merged via squash.
|
* fix: release Android camera snap use case * fix(android): release one-shot camera capture promptly --------- Co-authored-by: NianJiuZst <180004567+users.noreply.github.com> Co-authored-by: Peter Steinberger <[email protected]>
* fix: release Android camera snap use case * fix(android): release one-shot camera capture promptly --------- Co-authored-by: NianJiuZst <180004567+users.noreply.github.com> Co-authored-by: Peter Steinberger <[email protected]>



What Problem This Solves
Android
camera.snapbound a one-shot CameraXImageCaptureuse case but did not release that use case after the capture completed. That could leave the camera pipeline active after a single still capture, unlikecamera.clip, which explicitly unbinds its capture use cases after recording.Why This Change Was Made
This wraps the still-capture work in a
finallycleanup and unbinds only theImageCaptureinstance owned by the current invocation. The cleanup is scoped to the snap use case instead of using a finalunbindAll(), so a completed snap does not tear down a newer camera invocation that may have bound its own use cases.User Impact
Users invoking Android camera snaps should no longer leave the camera active after a successful, failed, or cancelled still capture. Concurrent or immediately-following camera work is less likely to be disrupted because the final cleanup only targets the completed snap's use case.
Evidence
cd apps/android && ./gradlew :app:testThirdPartyDebugUnitTest --tests ai.openclaw.app.node.CameraHandlerTest --tests ai.openclaw.app.node.JpegSizeLimiterTestgit diff --check.agents/skills/autoreview/scripts/autoreview --mode branch --base origin/main