Skip to content

v3.0.14

Choose a tag to compare

@Dregi56 Dregi56 released this 24 Feb 14:07
a032ac8

🐛 Bug Fix — Language Detection

Fixed an issue where the voice announcement was spoken in Italian regardless of the language set in Home Assistant.

Root cause: Home Assistant can return language codes in extended format (e.g. en-GB, en-US), which were not matched against the internal translations dictionary. As a result, the integration fell back to a hardcoded Italian string.

What changed in digital_pendulum.py:

  • Added a _normalize_language() method that correctly strips the region suffix from the HA language code (e.g. en-GBen)
  • Changed the default fallback language from Italian to English for unsupported languages
  • Applied the fix consistently to both the scheduled announcements and the test announcement