gradio-app/gradio

Recorded audio (microphone) is duplicated and is in x2 speed (linux/firefox)

Opened this issue · 3 comments

Describe the bug

I'm trying to use the audio component on gradio 4.x to record audio over microphone. I can launch the record but when I click the STOP button the audio is duplicated (there is 1 audio but the record is audible twice in a row) and it is speed up (times 2 I guess...)

Note that I've got the problem on the official audio component demo as well but the audio appears normally for a short period of time (less than a sec) and then appears duplicated.

This bug seems to only appears with Firefox on Linux (linux/chromium is OK and MacOS/Firefox is OK). However I selected "Blocking usage of gradio" severity because our app purpose is to go online, therefore we are not able to upgrade from gradio 3.50.2 for now.

Have you searched existing issues? 🔎

  • I have searched and found no existing issues

Reproduction

import gradio as gr

with gr.Blocks() as demo:
    gr.Audio()

demo.launch()

Screenshot

This screen record is from the official the official audio component demo

issue_gradio_audio_component

Logs

No error or warning from python local server, however the in-browser javascript console got this warning that repeats itself indefinitely as soon as the bug occurs:

Invalid URI. Load of media resource  failed.

(It doesn't tell me which file trigger the warning exactly)

System Info

User agent: 
Mozilla/5.0 (X11; Linux x86_64; rv:122.0) Gecko/20100101 Firefox/122.0

OS:
Distributor ID:	Linuxmint
Description:	Linux Mint 21.2
Release:	21.2
Codename:	victoria

Python:
Version 3.10.12

Gradio: 
4.16.0 (fresh install)

Severity

Blocking usage of gradio

Edit: update the screen recorder that was corrupted

Hi everyone, I'm facing the same problem. Any help?

I am having the same problem on firefox in linux as well. Using chrome on windows, I get some clipping instead.

I am having the same problem on firefox in linux as well. Using chrome on windows, I get some clipping instead.

I don't know if if this is related but I can't play back audio recorded from microphone when using chrome on android.