v3.0.14
🐛 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-GB→en) - 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