mini-graph-card icon indicating copy to clipboard operation
mini-graph-card copied to clipboard

Graph doesn't fully render outside local network

Open Balok-Fesarius opened this issue 1 year ago • 6 comments

I've got an air quality graph in home assistant that works fine when accessed within my local network, but only partially renders when accessed via the internet. Any ideas?

HA is accessed using a custom domain through Nginx Proxy Manager.


Local Network IMG_1177

Via Internet IMG_1178

Balok-Fesarius avatar Mar 04 '24 22:03 Balok-Fesarius

Can you see same with a standard "history-graph"?

ildar170975 avatar Mar 04 '24 23:03 ildar170975

Can you see same with a standard "history-graph"?

Yes, That works both on and off-site.

Here's the code for the graph using your add-in that's failing when remote:

- type: 'custom:mini-graph-card'
  name: Outside AQI History
  entities:
  - entity: sensor.purpleair_aqi
  align_header: center
  align_state: center
  animate: false
  color_thresholds: &graphThresholdColors [
    { color: "#00ff00",  value: 0   },
    { color: "#ffff00",  value: 51  },
    { color: "#ff7e00",  value: 101 },
    { color: "#ff0000",  value: 151 },
    { color: "#8f3f97",  value: 201 },
    { color: "#7e0023",  value: 301 } ]                                      
  color_thresholds_transition: smooth
  decimals: 0
  font_size: 100
  font_size_header: 18
  height: 180
  hours_to_show: 24
  line_width: 6
  points_per_hour: 6
  show:
    extrema: false
    icon: false
    labels: true
    labels_secondary: false
  unit: AQI

Balok-Fesarius avatar Mar 08 '24 21:03 Balok-Fesarius

No idea))). Have you tried purging a browser's cache?

ildar170975 avatar Mar 08 '24 22:03 ildar170975

Maybe, Lovelace uses the websocket api: https://developers.home-assistant.io/docs/api/websocket . While we use the rest API (I think): https://developers.home-assistant.io/docs/api/rest .

I have no idea though, why that would behave differently.

akloeckner avatar Mar 13 '24 21:03 akloeckner

UPDATE: Please ignore this. I did a full reboot on every device (router, laptop, Home Assistant). And it's working across all devices again. Leaving the message to show how I fixed my issue.


Original message: I have the same problem. Using Safari and accessing via the local IP address directly to the Raspberry Pi, the graphs display correctly. They also display correctly in the iPhone iOS app. But if I try to use the external address, the graph displays as above, greyed out with a max and min of 0.

I have tried clearing cache and cookies to no avail. I'm using 0.12.0

I did update the Core and Supervisor to 2024.3.0 and 2024.03.0 respectively, that's the only updates I remember doing in the last few days.

Quick update: Firefox displays correctly, but Safari doesn't...

HypeLaser avatar Mar 14 '24 02:03 HypeLaser

I have a similar issue:

  • From local lan -> it works
  • From VPN -> The custom card is missing

That's awfully strange

Darathor17 avatar Sep 04 '24 20:09 Darathor17