mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-07 11:28:35 -05:00
[GH-ISSUE #23695] issue: Voice recording interrupted by screen lock on iPhone PWA (Wake Lock API missing in VoiceRecording component) #35576
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @fischerkev7 on GitHub (Apr 14, 2026).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/23695
Check Existing Issues
Installation Method
Other
Open WebUI Version
V08.10
Ollama Version (if applicable)
No response
Operating System
Azure Container Web App Linux
Browser (if applicable)
No response
Confirmation
README.md.Expected Behavior
When using the voice recording button (microphone icon) in the chat input on an iPhone PWA, the screen should remain on for the duration of the recording session — just as it does in the Call Overlay, which already implements the Wake Lock API.
Actual Behavior
After a few seconds of inactivity (no screen touch), the iPhone screen turns black and the device locks. This immediately interrupts the audio recording. The recorded audio up to that point is lost and no transcription is sent.
This affects the VoiceRecording component (microphone button in the chat input). The CallOverlay component already has Wake Lock implemented and is not affected.
Steps to Reproduce
Logs & Screenshots
No JavaScript errors are thrown. The issue is a missing browser API call — navigator.wakeLock.request('screen') is never called in VoiceRecording.svelte.
For reference: CallOverlay.svelte already contains a working Wake Lock implementation (onMount, lines 626–652).
Related discussions:
#3031 — "when doing voice-to-text the screen will lock at the most inopportune time"
#18627 — iOS mic cutoff issue where a user confirmed Wake Lock prevents the problem
Additional Information
Root cause: VoiceRecording.svelte does not use the Wake Lock API, while CallOverlay.svelte already does.
Proposed fix: Add Wake Lock to VoiceRecording.svelte — request it when mediaRecorder.onstart fires, release it in stopRecording(), confirmRecording(), and onDestroy(). Re-request on visibilitychange (same pattern as CallOverlay).
Compatibility: Wake Lock API is supported since iOS 16.4 (Safari). The fix includes 'wakeLock' in navigator guards for graceful fallback on older devices.
I am willing to submit a pull request
@Classic298 commented on GitHub (Apr 14, 2026):
Wake lock added in dev. Duplicate. Search for existing issues before opening one!!!