Python 语音助理没有被终止
您好,我目前正在制作一个语音助手,我想终止它,但它没有终止,只是得到重复Python 语音助理没有被终止,python,python-3.x,api,pyttsx,pyttsx3,Python,Python 3.x,Api,Pyttsx,Pyttsx3,您好,我目前正在制作一个语音助手,我想终止它,但它没有终止,只是得到重复 elif 'you can sleep now' in query or 'take rest' in query: speak('ohk master I am going to sleep you can call me again anytime going to sleep in 3 ,2 , 1') break if __nam
elif 'you can sleep now' in query or 'take rest' in query:
speak('ohk master I am going to sleep you can call me again anytime going to sleep in 3 ,2 , 1')
break
if __name__ == "__main__":
while True:
permission = takeCommand()
if 'wake up' in permission:
task_execute()
elif 'close' in permission or 'buy' in permission:
speak('ok sir have a good day')
exit()
<> > <代码>破解< /代码>在代码> > Script()/代码>从循环中中断。< /P>添加<代码>破解< /代码> <代码> > <代码> >我已经添加了中断,NVM修复了这个问题,把它写为答案,这样我就可以回答它了。