Could not start audio source linux get User Media

That is literally all it will tell me. “Could not start audio source" DOMException message, and a name of “NotReadableError”. It prints the enumerated devices fine. I can get the deviceId and try passing that as the constraint, same thing. I can try getting audio with the desktopCapturer, same thing. I’m smashing my head over this.

Firefox websites request the microphone fine, as does chromium.

I’m running everything in a vncserver x session because it’s on a vps. It’s running ubuntu 18.04. I also tried this in a different vps running debian 8 and it didn’t run there either. Chrome/chromium/electron doesn’t detect pulseaudio’s monitor of output as an input source (firefox and every other flippin program does), so I had to make a virtual microphone in pulseaudio which is what chrome/chromium/electron detects.

I don’t know what else to try. Please help if you can. Let me know if any other info would be relevant.

Well I figured something out. It gives me the same error when I use vnc4server or make an Xvfb screen. But if I use X11 forwarding to my windows pc running Xming, then it actually loads the audio fine. I still don’t understand what the problem is or how to go about fixing it though. Please help if anyone knows some troubleshooting steps for this.

Any clues in this thread?

I can’t find the edit button on this site. I got it working now. All it needed was a freaking setTimeout delay before trying to grab it. It was working via X11 forwarding because it takes so long to start there.