nateshmbhat / pyttsx3

Offline Text To Speech synthesis for python
Mozilla Public License 2.0
1.99k stars 321 forks source link

NSSS MacOS Ventura workaround #267

Open egorgam opened 1 year ago

egorgam commented 1 year ago

If I trying to save TTS result to file in MacOS Ventura (on Apple Silicon CPU), pyttsx3 generating empty file with 4kb size.

I found a simple way to fix it - adding a small timeout after saving operation. Looks like engine.runAndWait() closing loop before file content is saving. Maybe a reason in Apple Silicon CPU speedup, or it's pyobj bug. However, this workaround is working, and someone can found better solution in future.

codeaye commented 1 year ago

I have the exact same issue.. but unfortunately your fix does not seem to work.

codeaye commented 1 year ago

Actually, i have checked with your fix and found that the time waited needs to grow in response to the size of text you are converting. Thus this fix wouldnt exactly work for everyone 😅

codeaye commented 1 year ago

Ive found an actual fix instead of a workaround here: https://github.com/nateshmbhat/pyttsx3/pull/271