HADashboard Entity Picture Widget not working in HA 0.93.2

I have been using the ‘entity picture’ widget successfully on all my dashboards for some time.
I am running Hass.io on Pi and when i upgraded HA to 0.93.2 this widget seems to stop working on all my dashboards.
while nothing is playing it stays blank as per normal but when i have the google speaker playing something, instead of displaying the image i see in HA it displays a broken image icon similar to this:
images

If i restore my snapshot of HA 0.92.2 it all works fine again.
Here is the code from one of my dashboard files:

media_album_cover:
    widget_type: entitypicture
    entity: media_player.kitchen_speaker
    base_url: https://myaddress.duckdns.org:8123
    image_style: "top: 0; bottom: 0; left: 0; right: 0;"

Has anyone else had similar issues and know of a fix?

For reference I’m using Hass.io on Raspberry Pi with AppDaemon 3.0.2 loaded through the add-on store.

What error do you get in the javascript console?

Hi @tjntomas
Im not too used to the Java console but looking in the developers tools in chrome there do not appear to be any errors.

however when inspecting the element when running HA 92.2 it has the following:

<img class="img-frame" data-bind="attr: {src: img_inernal_src, style: img_internal_style}" src="https://redacted.duckdns.org:8123/api/media_player_proxy/media_player.bathroom_speaker?token=8b----redacted----f7&amp;cache=aff21e51bd25d62c" style="">

This is the working version and if I paste the https link into a new tab I get the album image.

However in HA 93.2 when I inspect the same element I get the following:
<img class="img-frame" data-bind="attr: {src: img_inernal_src, style: img_internal_style}" src="https://redacted.duckdns.org:8123http://cdn-albums.tunein.com/gn/J8BRMQQMPVg.jpg" style="">
This is the one that gives the broken image link and when i copy the http part into a new tab i get a 404 error.
If i just take the last part:
http://cdn-albums.tunein.com/gn/J8BRMQQMPVg.jpg
and put in a new tab it shows the album cover.

So it appears to me the way HADashboard gets the image for the widget has changed from version 92.2 to 93.2 and for some reason is trying to fetch the image from a combination my HA address and the image address.

This feels like a bug rather than something I’m doing wrong but happy to be pointed in the correct direction.

Many thanks

I guess the album image path is an attribute of the media_player.kitchen_speaker entity. Can you post the attributes for that entity from the dev-state panel in HA? I suspect HA changed the way it stores the path in the attribute and the widget would then need a minor update.

Yes, I meant the developers tools.

Try removing this line from your widget def.

1 Like

In HA 92.2 the attribute is as follows:

volume_level: 0.11999999731779099
is_volume_muted: false
media_content_id: http://tx.planetradio.co.uk/http_live_bauer.php?i=absoluteradio.mp3&awparams=loggedin:false&amsparams=playerid:BMUK_tunein
media_content_type: music
media_position: 382.30342
media_position_updated_at: 2019-05-28T19:02:56.983620+00:00
media_title: Republica - Drop Dead Gorgeous
media_artist: Absolute Radio
app_id: 12F05308
app_name: TuneIn Free
friendly_name: Bathroom Speaker
entity_picture: /api/media_player_proxy/media_player.bathroom_speaker?token=8b------redacted-------&cache=dde2f7d9355ba0ca
supported_features: 21389
icon: mdi:speaker-wireless

I’m upgrading to 93.2 and will post the attribute once upgrade finishes.
I will also try removing the base url from the widget in the dash file and let you know how it goes.

HI @tjntomas

Upraded to HA93.2 and removed the baseurl fron the widget in the dash file and that seems to have fixed it.

Many thanks for your help on this.

1 Like