Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

MediaDevices.getUserMedia() is not supported on your browser

See original GitHub issue


  • Leon version: 97311aa1b4a51a82e2532ac91bfa6a3570b89dff
  • OS (or browser) version: Ubuntu 18.10 Docker-CE
  • Node.js version: 10-alpine
  • Complete “npm run check” output:
  • (if using Docker) Complete “npm run docker:check” output:
docker run --rm -it -p 1337:1337 leon npm run check

> leon@1.0.0-beta.3 check /app
> babel-node scripts/run-check.js



➡ /bin/sh -c node --version
✔ v10.15.3

➡ /bin/sh -c npm --version
✔ 6.4.1

➡ /bin/sh -c pipenv --version
✔ pipenv, version 2018.11.26

➡ /bin/sh -c pipenv --where
✔ /app/bridges/python

➡ /bin/sh -c pipenv run python --version
✔ Python 3.6.8

➡ /bin/sh -c pipenv run python bridges/python/ scripts/assets/query-object.json
✔ {"package": "leon", "module": "randomnumber", "action": "run", "lang": "en", "input": "Give me a random number", "entities": [], "output": {"type": "end", "codes": ["success"], "speech": 82, "options": {}}}

➡ Classifier state
✔ Found and valid

➡ Amazon Polly TTS
❗ Amazon Polly TTS is not yet configured

➡ Google Cloud TTS/STT
❗ Google Cloud TTS/STT is not yet configured

➡ Watson TTS
❗ Watson TTS is not yet configured

➡ Offline TTS
❗ Cannot find bin/flite/flite. You can setup the offline TTS by running: "npm run setup:offline-tts"

➡ Watson STT
❗ Watson STT is not yet configured

➡ Offline STT
❗ Cannot find bin/deepspeech/lm.binary. You can setup the offline STT by running: "npm run setup:offline-stt"


.: REPORT :.

➡ Here is the diagnosis about your current setup
✔ Run
✔ Run modules
✔ Reply you by texting
❗ Amazon Polly text-to-speech
❗ Google Cloud text-to-speech
❗ Watson text-to-speech
❗ Offline text-to-speech
❗ Google Cloud speech-to-text
❗ Watson speech-to-text
❗ Offline speech-to-text

✔ Hooray! Leon can run correctly
➡ If you have some yellow warnings, it is all good. It means some entities are not yet configured
  • (optional) Leon package version:

Expected Behavior

Ask me for permission to access my mic

Actual Behavior

main.js:469 MediaDevices.getUserMedia() is not supported on your browser.

How Do We Reproduce?

Click the mic icon

Extra (like a sample repo to reproduce the issue, etc.)

Using Chrome 74.0.3729.131

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (10 by maintainers)

github_iconTop GitHub Comments

SuperSandro2000commented, May 21, 2019

Hey! It seems you are going for a sleepless night, be careful. Got it working! pr ist here #99

I am looking into the speech stuff hopefully the next days and send PRs or open issues if I encounter new problems.

Btw where does leon store its data? We would need to add a volume for that one.

louistiticommented, May 19, 2019

Alright, I think I’ve found the origin of the problem, it should be related to this.

Chrome disables features such as getUserMedia when it comes from an unsecured origin. http://localhost is considered as a secure origin by default, however if you use an origin that does not have an SSL/TLS certificate then Chrome will consider the origin as unsecured and disable getUserMedia.

What you can do is:

  1. Setup an SSL/TLS certificate.
  2. Or go to chrome://flags, search for the flag unsafely-treat-insecure-origin-as-secure, enter the origin you want to treat as secure such as http://{YOUR HOST IP}:1337, enable the feature and relaunch the browser.

Let me know if that works.

Read more comments on GitHub >

github_iconTop Results From Across the Web

getUserMedia() not supported in chrome - Stack Overflow
Starting with Chrome 47, getUserMedia() requests are only allowed from secure origins: HTTPS or localhost. ...
Read more >
MediaDevices.getUserMedia() - Web APIs | MDN
The MediaDevices .getUserMedia() method prompts the user for permission to use a media input which produces a MediaStream with tracks ...
Read more >
Getting 'getUserMedia is not implemented in this browser' #47
Hi, I'm receiving getUserMedia is not implemented in this browser from the error event when run on iOS chrome and firefox, but not...
Read more >
getUserMedia/Stream API | Can I use... Support ... - CanIUse
As of Chrome 47, the getUserMedia API cannot be called from insecure origins. 1 Blink-based (and some other) browsers support an older version...
Read more >
Error " Your browser does not support media devices"
How can I fix that ? startStreaming: function() { const mediaSupport = 'mediaDevices' in navigator; if (mediaSupport && null ==
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found