dreimer1986 / lovelace-animated-background

Animated backgrounds for lovelace
18 stars 5 forks source link

Not Working #3

Closed mmatus1112 closed 1 year ago

mmatus1112 commented 1 year ago

Hi,

I have been trying to make this repository to work but no luck...

I have:

1) Uninstalled previous Animated Background installation 2) Removed the resources javascript from my dashboard 3) Restarted my HA 4) Reinstalled Animated Background. When installing, I see a message that the repository will be installed in /local/community/lovelace-animated-background 5) I go to my dashboard and I add the resource as a javascript -> /hacsfiles/lovelace-animated-background/animated-background.js 6) I go to my raw editing and I add the following:

'' animated_background: default_url: https://static.videezy.com/system/resources/previews/000/012/073/original/Fire_46_-_45s_-_4k_res.mp4 opacity: 80 entity: weather.kmia_daynight state_url: sunny:

After all the steps, I still cannot see the animated background. Please help!

dreimer1986 commented 1 year ago

I smell the Browser Cache as culprit... In the big report I made in the original repo I fell for it, too. So hard that I fixed my faulty Cache with another JS file. ^^ https://github.com/Villhellm/lovelace-animated-background/issues/56

OK, first things first: /hacsfiles/lovelace-animated-background/animated-background.js looks good, but I am sure it's the same path as it was before with the original addon, right? If so, change it to: /hacsfiles/lovelace-animated-background/animated-background.js?v=10 This does not change anything on the script at all, but forces a reload in the browser Cache.

To finally force it, go back to main Dashboard and Push F12 to open the dev console. Move it aside and make a right click on the refresh button. Choose "Clear Cache and complete reload" or something like this. Then MAYBE it should work.

If it does and you ever have problems with it, you could try this one, too. https://github.com/dreimer1986/yourname_card_mod/blob/master/README-script.md This is my own madness that touches the whole way deeper in the website tree and thus is almost impossible to be ever b0rked by any update.

If not, tell me ^^

wanmeich520 commented 1 year ago

the same problem as me

mmatus1112 commented 1 year ago

I smell the Browser Cache as culprit... In the big report I made in the original repo I fell for it, too. So hard that I fixed my faulty Cache with another JS file. ^^ Villhellm#56

OK, first things first: /hacsfiles/lovelace-animated-background/animated-background.js looks good, but I am sure it's the same path as it was before with the original addon, right? If so, change it to: /hacsfiles/lovelace-animated-background/animated-background.js?v=10 This does not change anything on the script at all, but forces a reload in the browser Cache.

To finally force it, go back to main Dashboard and Push F12 to open the dev console. Move it aside and make a right click on the refresh button. Choose "Clear Cache and complete reload" or something like this. Then MAYBE it should work.

If it does and you ever have problems with it, you could try this one, too. https://github.com/dreimer1986/yourname_card_mod/blob/master/README-script.md This is my own madness that touches the whole way deeper in the website tree and thus is almost impossible to be ever b0rked by any update.

If not, tell me ^^

Thank you for the response! So I have followed your steps but no luck. I did the following:

1) Uninstalled "animated background" from HACS. 2) Made sure the "Lovelace Dashboard Animated Background Resource" was removed. 3) Cleared my "Edge" cache from ALL TIME. 4) Restarted my browser. 5) Reinstall "lovelace animated background" in HACS. I insist that I get the following message in the pop-up window "When downloaded this will be located in '/config/www/community/lovelace-animated-background'" Please note I am installing version 0.6.3 6) When I go to add the "Lovelace Dashboard Animated Background Resource", I see that a resource is added automatically -> /hacsfiles/lovelace-animated-background/animated-background.js?hacstag=202743061063 7) Should I keep that one or add the one stated in the repository description > /hacsfiles/lovelace-animated-background/animated-background.js? 8) If I leave the one added automatically, and copy the code of Step 3, it does not work. I refresh my web browser but still no luck. 9) If I delete the resource added automatically and copy the one stated in Step 2, it still does not work. 10) If I add the resource as you stated in your comment -> /hacsfiles/lovelace-animated-background/animated-background.js?v=10, still no luck.

Any other suggestions?

dreimer1986 commented 1 year ago

If the hacstag is there all should be OK. No need for my v=10. (Normally.... it's worth a try to remove the hacstag and add my stuff)

Try another browser to be sure it's not still some leftover cache.

It worked for many ppl and still works on 2023.5.X, so something on your side is the problem. What you can try is to move the animated-background.js from /local/community/lovelace-animated-background to /local/community as test and change the value to: /hacsfiles/animated-background.js

Otherwise I have no clue what is wrong and have no logs to help with it... Logs = Open F12 DevTools and give me the console output.

dreimer1986 commented 1 year ago

Status?

mmatus1112 commented 1 year ago

Alright, so here is my take on this:

1) If I try the HACS method of installation, it does not work. 2) If I try the manual installation, it works perfectly.

Not really sure what the issue is with the HACS method of installation but I was not able to make it work.

Thanks!!!

dreimer1986 commented 1 year ago

Hmm... ok? Strange. I wonder what is different in that case. In theory nothing should differ file wise at least.