Skip to content

[MS-1544] Fixing issue with auto-capture. 'Start capture' now properly starts capturing - #1785

Merged
alexandr-simprints merged 1 commit into
mainfrom
MS-1544-start-capture-doesnt-start-capture
Aug 13, 2026
Merged

[MS-1544] Fixing issue with auto-capture. 'Start capture' now properly starts capturing#1785
alexandr-simprints merged 1 commit into
mainfrom
MS-1544-start-capture-doesnt-start-capture

Conversation

@alexandr-simprints

Copy link
Copy Markdown
Contributor

JIRA ticket
Will be released in: 2026.3.0

Root cause analysis (for bugfixes only)

First known affected version: 2026.2.0
Start capture button does not start capturing until pressed for the second time.

start-capture-bug.mp4

Notable changes

  • State management is fixed to consider the auto capture config

Testing guidance

  • Describe how the reviewers can verify that issue is fixed

Additional work checklist

  • Effect on other features and security has been considered
  • Design document marked as "In development" (if applicable)
  • External (Gitbook) and internal (Confluence) Documentation is up to date (or ticket created)
  • Test cases in Testiny are up to date (or ticket created)
  • Other teams notified about the changes (if applicable)

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses a regression in face auto-capture where tapping “Start capture” would not begin capturing until the second press, by adjusting how the UI/state machine treats the “auto-capture held off” period.

Changes:

  • Exposes isAutoCaptureHeldOff from LiveFeedbackViewModel (read-only externally) so the UI can react to it.
  • Updates LiveFeedbackFragment button feedback rendering to suppress guidance only while auto-capture is explicitly held off (instead of keying off phase != CAPTURING).

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
face/capture/src/main/java/com/simprints/face/capture/screens/livefeedback/LiveFeedbackViewModel.kt Makes isAutoCaptureHeldOff externally readable to support correct auto-capture start behavior.
face/capture/src/main/java/com/simprints/face/capture/screens/livefeedback/LiveFeedbackFragment.kt Uses the held-off flag when deciding whether to show guidance on the capture button in auto-capture mode.
Suppressed comments (1)

face/capture/src/main/java/com/simprints/face/capture/screens/livefeedback/LiveFeedbackFragment.kt:318

  • renderFeedbackOnButton now depends on vm.isAutoCaptureHeldOff, which is outside the LiveFeedbackState single-source-of-truth. This can lead to UI not re-rendering when only isAutoCaptureHeldOff changes (no state emission), and it breaks the stated deterministic rendering contract. Prefer carrying this flag in LiveFeedbackState (or exposing it as a Flow/StateFlow) and rendering purely from state.
        val feedback = if (state.isAutoCapture && vm.isAutoCaptureHeldOff) {
            LiveFeedbackState.Feedback.NONE
        } else {
            state.feedback
        }

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@sonarqubecloud

Copy link
Copy Markdown

@alexandr-simprints
alexandr-simprints merged commit ddbcdda into main Aug 13, 2026
15 checks passed
@alexandr-simprints
alexandr-simprints deleted the MS-1544-start-capture-doesnt-start-capture branch August 13, 2026 12:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants