I'm using python with anaconda.
AttributeError: module 'pydub' has no attribute 'playback'
I get the error above when I try to run the following statement:
speech = pydub.AudioSegment.from_mp3("temp_speak.mp3")
pydub.playback.play(speech)
the problem is , I can see there is a module called playback in the auto completition of visual studio code , besides that , when I get to the
~/anaconda3/envs/env_name/lib/python3.7/site-packages/pydub
I can see that there is a file named playback and its not corrupted.
here is the output of ls :
audio_segment.py generators.py playback.py scipy_effects.py
effects.py __init__.py pyaudioop.py silence.py
exceptions.py logging_utils.py __pycache__ utils.py
And I'm sure that I'm activating the environment before I run my script.