Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Picture-entity: picture not loaded in the Android App #838

Closed
LorenzoVasi opened this issue Aug 28, 2020 · 5 comments
Closed

Picture-entity: picture not loaded in the Android App #838

LorenzoVasi opened this issue Aug 28, 2020 · 5 comments
Labels
bug Something isn't working webview

Comments

@LorenzoVasi
Copy link

Home Assistant Android version:
2.3.0-306-full
Android version:
Android 10
Phone model:
Google Pixel 3A
Home Assistant version:
HassOS 4.12 - Home Assistant 0.114.4
Last working Home Assistant release (if known):
//
Description of problem:

Hi,
in my Home Assistant i add a picture-entity, where i take an image from this link
http://www.prolocobogliasco.it/webcam/current_hd.jpg
In all browsers (PC and Phone) this image loads but only in the app it doesnt load

Traceback (if applicable):


Screenshot of problem:

image
image

Additional information:

Sorry, im italian and my english is very bad. :)

@LorenzoVasi LorenzoVasi added the bug Something isn't working label Aug 28, 2020
@dshokouhi
Copy link
Member

I was able to reproduce this with the following card setup

 - type: picture-entity
   entity: weather.dark_sky
   image: http://www.prolocobogliasco.it/webcam/current_hd.jpg

Not really sure why it doesn't load in the app but does in chrome 🤔

@dshokouhi
Copy link
Member

dshokouhi commented Aug 28, 2020

@LorenzoVasi do you have SSL setup? I wonder if this is an issue where we are using mixed content because I just realized the link is non-secure and in my setup I am using SSL so the image probably did not load due to the mixup there. We may need to test this when using http to connect to home assistant instead of a secure setup. We also can't convert the link to https as its not a valid certificate. What happens if you try this url https://i.imgur.com/o2Fdv35.jpeg does it load as expected?

Edit: changing the URL to a secure one like my example works for me so the issue is with mixed content.

@LorenzoVasi
Copy link
Author

LorenzoVasi commented Aug 28, 2020

https://i.imgur.com/o2Fdv35.jpeg <-- This image loads withouts problem, i think u are right...
Anyway, i don't want to disable https for only an image because my HA is open on web ...
What can i do without disable https for this image?
http://www.prolocobogliasco.it/webcam/current_hd.jpg
I cant download it because this image changes every 5 minutes

@JBassett
Copy link
Collaborator

@LorenzoVasi if you turn the image into a camera in home assistant then it will be served by your home assistant instance. I do something similar for a weather radar image:

camera:
  - platform: generic
    name: Radar
    still_image_url: http://radblast.wunderground.com/cgi-bin/radar/WUNIDS_map?station=BUF&brand=wui&num=6&delay=15&type=N0R&frame=0&scale=1.000&noclutter=0&showstorms=0&mapx=400&mapy=240&centerx=400&centery=240&transx=0&transy=0&showlabels=1&severe=0&rainsnow=0&lightning=0&smooth=0&rand=25396520

@LorenzoVasi
Copy link
Author

Ok, now it works :))))) I love u <3
In this code

camera:
  - platform: generic
    name: Radar
    still_image_url: 

I add this:

verify_ssl: false

Thank u for all!!! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working webview
Projects
None yet
Development

No branches or pull requests

3 participants