我正在使用在Windows主机中运行的ubuntu虚拟机中运行的ubuntu docker容器。我已经在我的ubuntu docker容器中安装了所有必需的软件包(apt更新,apt升级,python3,pip3,pyttsx3,alsa-utils)。当我尝试运行以下代码时:
engine = pyttsx3.init()
engine.say("hello")
engine.runAndWait()
我遇到以下错误
ALSA lib confmisc.c:767:(parse_card) cannot find card '0'
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory
ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory
ALSA lib confmisc.c:1246:(snd_func_refer) error evaluating name
ALSA lib conf.c:4732:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5220:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2642:(snd_pcm_open_noupdate) Unknown PCM default
aplay: main:830: audio open error: No such file or directory