Skip to content

v1.10.3#286

Merged
TiTidom-RC merged 3 commits into
betafrom
dev
Jun 23, 2026
Merged

v1.10.3#286
TiTidom-RC merged 3 commits into
betafrom
dev

Conversation

@TiTidom-RC

Copy link
Copy Markdown
Owner

This pull request focuses on improving the robustness and clarity of TTS (Text To Speech) file handling, especially for JeedomTTS and VoiceRSS integrations, and updates dependencies and plugin metadata. It also standardizes and clarifies log messages, particularly error reporting, mostly translating them to French for consistency.

TTS file handling improvements:

  • Improved JeedomTTS integration to properly decode and validate the returned file path, handle whitespace issues, and log detailed warnings if the TTS file is missing or invalid.
  • Enhanced VoiceRSS integration by validating MP3 responses using magic bytes, and logging warnings for invalid (non-MP3) responses.

Logging and error message standardization:

  • Translated and standardized error and warning log messages throughout the TTS generation and test flows to French, making logs more consistent and user-friendly. [1] [2] [3] [4] [5] [6] [7] [8] [9]
  • Improved logging details, such as using %d for integer formatting and providing more context in error messages.

Dependency and metadata updates:

  • Updated google-cloud-texttospeech to 2.37.0 and google-genai to 2.9.0 in requirements.txt for improved compatibility and features.
  • Bumped plugin version from 1.10.2 to 1.10.3 in plugin_info/info.json.

Development environment:

  • Added "espeak" and "pico" to the list of recognized words in .vscode/settings.json to reduce false positives in spell checking for TTS-related dependencies. [1] [2]

Handle Jeedom tts.php responses that return a file path: decode and strip response content, verify path with os.path.exists, and read file with a context manager. Replace several English log messages with French equivalents for consistency and improve debug formatting (use %d for length). Add missing "espeak" and "pico" entries to VSCode settings and bump plugin version to 1.10.3 in plugin_info.
Check HTTP response content from VoiceRSS for MP3 magic bytes before using it. The code now verifies status code and that response.content starts with ID3 or an MPEG sync frame (0xFF 0xE0+); if not, it logs a warning (showing up to 80 chars of the response) and avoids treating the payload as audio. Assigns filecontent only when valid and removes the previous unused/incorrect handling. This prevents non-MP3 API errors or HTML responses from being processed as audio.
Bump dependency versions in resources/requirements.txt: google-cloud-texttospeech 2.36.0 -> 2.37.0 and google-genai 2.8.0 -> 2.9.0. These upgrades bring minor fixes and improvements from the newer releases.
@TiTidom-RC
TiTidom-RC merged commit bfa2ddf into beta Jun 23, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant