Comments (10)
When you're calling the function at the end, use a try-except block to handle the exceptions. See this ↙
while True:
try:
run_alexa()
except UnboundLocalError:
print("No command detected! Alexa has stopped working ")
break
Hope this'll work!
from romantic-alexa.
Try this (in admin mode command prompt):
pip install pipwin pipwin install pyaudio
Thanks bro it is working properly now
from romantic-alexa.
pip install pyaudio
solved this problem for me. speech_recognition was throwing an error without it
from romantic-alexa.
Try this (in admin mode command prompt):
pip install pipwin
pipwin install pyaudio
from romantic-alexa.
When you're calling the function at the end, use a try-except block to handle the exceptions. See this ↙
while True: try: run_alexa() except UnboundLocalError: print("No command detected! Alexa has stopped working ") breakHope this'll work!
not working
new error :
IndentationError: expected an indented block
from romantic-alexa.
not working
new error :
IndentationError: expected an indented block
Check the indentation of your code properly!..🤷♂️
from romantic-alexa.
from romantic-alexa.
Try this (in admin mode command prompt):
pip install pipwin pipwin install pyaudio
worked for me
from romantic-alexa.
I did this and just it extends a little more before error
while True:
try:
run_alexa()
except UnboundLocalError:
print("No command detected! Alexa has stopped working ")
run_alexa()
I think is needed to handle the UnboundLocalError: local variable 'command' referenced before assignment
from romantic-alexa.
This a Lousy solution but at least it will continue listening:
while True:
try:
run_alexa()
except UnboundLocalError:
print("No command detected! Alexa has stopped working ")
command = "."
from romantic-alexa.
Related Issues (20)
- showing module error HOT 1
- Code is not working HOT 2
- FIX: HOT 2
- How to make alexa to open youtube and other sites HOT 1
- UnboundLocalError
- what is the problem? HOT 6
- UnboundLocalError: cannot access local variable 'command' where it is not associated with a value HOT 3
- Inquiring
- i did install and tried all other fixes possible but this keeps coming up HOT 1
- I am facing those errors
- anyone knows how to solve this error? HOT 1
- Unbound error
- this error occur whenever i run the program HOT 1
- Problem in installing packcages HOT 1
- Command issue HOT 1
- UnboundLocalError: cannot access local variable 'command' where it is not associated with a value HOT 1
- I don't know what error is this
- no module named speechRecognition
- requirements.py file missing also specific version of packages
- It is Giving me an error
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from romantic-alexa.