Localized state string

Hi,
Is there any way to, from a python-script, get access to the localized version of the state string? Looking at weather.smhi in the UI, all states are in local language and there is a mapping in https://github.com/home-assistant/home-assistant-polymer/tree/master/translations/xx.json

How can I access the localized state from within a script?

Why do you want this? What are you trying to achieve?

I have a python-script that sends the state (weather condition) and other information to a LED display via mqtt and should be in local language.

That might be difficult. I don’t think it’s possible. I could be wrong so I’ll let someone else respond.

My best bet would be to create a template sensor and use that for the led display.

If there is no obvious solution to do it the right way, I will just copy the map i linked to above and make a dict in my python script. Not so beautiful, but it will work for now.
Thanks anyway.

The issue is that the frontend and backend are separated. They talk to each other, but i’m not sure if the backend has access to that aspect of the front end. You’d need to talk to someone who has intimate knowledge of both the front and backend.