$ python talk2.py
Traceback (most recent call last):
File "talk2.py", line 4, in <module>
esng.say('Hello World!')
File "/Users/miyurz/.pyenv/versions/anaconda3-5.2.0/lib/python3.6/site-packages/espeakng/__init__.py", line 103, in say
self._espeak_exe(args, sync=sync)
File "/Users/miyurz/.pyenv/versions/anaconda3-5.2.0/lib/python3.6/site-packages/espeakng/__init__.py", line 68, in _espeak_exe
stderr=subprocess.STDOUT)
File "/Users/miyurz/.pyenv/versions/anaconda3-5.2.0/lib/python3.6/subprocess.py", line 709, in __init__
restore_signals, start_new_session)
File "/Users/miyurz/.pyenv/versions/anaconda3-5.2.0/lib/python3.6/subprocess.py", line 1344, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
__init__.py:47: cmd = ['espeak-ng',
FileNotFoundError: [Errno 2] No such file or directory: 'espeak-ng': 'espeak-ng'
Fix:
1) Traverse to the code where cmd is hard coded to espeak-ng
@Miyurz can you install espeak-ng with brew? the espeak-ng git readme says espeak is a history version of espeak-ng before 2015.
If you change cmd to 'espeak', does all the api work as well?
https://github.com/gooofy/py-espeak-ng/blob/394826f351bbd693b0170927e654ca5e72ec5e6c/espeakng/__init__.py#L47
Earlier:
Fix: 1) Traverse to the code where cmd is hard coded to espeak-ng
2) Edit it to espeak
3) Brew installed espeak