Script :
from pydub import AudioSegment
sound = AudioSegment.from_mp3("/srv/python/welcome.mp3")
sound.export("/srv/python/test", format="wav")
ERROR:
IsADirectoryError: [Errno 21] Is a directory: '/srv/python/test'
path /srv/python/test
is exits with write permission (777) and /srv/python/welcome.mp3
is also exits
As per the
pydub
docstring for the method you're using (my emphasis):the parameter is supposed to be a file.
You appear to have provided a directory as the argument, so you may want to change it to something like: