Skip to content

Test for 'say' command for TTS fails on macOS #105

@MustBeArt

Description

@MustBeArt

In tts.py we check for the availability of the 'say' command for text-to-speech on macOS by trying to run 'say --version'. But say does not support the --version flag, at least not on recent versions of macOS. It returns a non-zero exit status, which makes subprocess.run (with check=True) raise a CalledProcessError exception, which is interpreted as meaning that the say command is not available.

Looks like you can say an empty string. That doesn't make any sound and it returns success.

subprocess.run(["say", ""], capture_output=True, check=True, timeout=5)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions