A huge change in the weather forecast (plus a new action in template sensors nobody talks about)

Sdílet
Vložit
  • čas přidán 1. 07. 2024
  • There is a change in the Weather forecast that came in the September Home Assistant release. For regular users, this probably does not mean anything, as I will show you. But as I discuss rather advanced topics on this channel, it might mean that some of us need to make some changes during the next 6 months, so let me show you how.
    This change builds on the recent introduction of service call return values, and also triggered an addition of an action parameter to the template sensor - and that’s quite exciting and useful in general. The great thing about that is, that you can say what type of weather forecast you want: daily, hourly, or twice_daily, and also, you should always get the latest forecast when you need it. The forecast attribute is now deprecated and will be removed 6 months from now.
    00:00 - intro
    04:00 - Scenario 1 - automation
    10:57 - Scenario 2 - template sensor
    16:10 - outro
  • Věda a technologie

Komentáře • 15

  • @trentfolan529
    @trentfolan529 Před 16 dny

    This is brilliant and so helpful. Thanks!

  • @christian1603
    @christian1603 Před 9 měsíci

    Thank you very much for this perfectly explained video, it helped me a lot!
    One problem, however: at the very beginning of the video (around 1 minute) you show how you can retrieve different types of forecasts (daily, hourly, twice daily) with one same weather entity.
    In my case I have created 3 OpenWeather map integration entries in the past, configured with mode hourly / onecall-hourly and onecall_daily.
    When calling the service weather.get_forecast with f.e. the weather entity "hourly", I only can chose for forecast type "hourly" (same for the daily weather entity only possible with forecast type daily).
    Any idea why, because I would like to have just one OpenWeather map integration.

  • @adfjasjhf
    @adfjasjhf Před 9 měsíci +8

    I'm not a fan of this change. Makes it way more harder for beginners to make a weather automatization. I think those templates which you created should be there already to make everything easier. Or perhaps some GUI with settings. We'll see in next update I guess.

    • @bruxy70
      @bruxy70  Před 9 měsíci +1

      I think the point is, if you are a beginner, this is seamless - you should not worry about the way the weather entity gets updated. You just use it, and it shows it. Use it on the weather forecast card, or click on the weather - it will show it! You do not need to worry about any of that.
      BUT, if you are using your own templates that use the forecast attribute and within the attribute, you are able to select the right date and the right attribute - then you are not a beginner, you are an advanced, or at least an intermediate user. So there is no point discussing beginners. So, now that we established that you are probably somewhat an advanced user, then the extra step to call the service is negligible (and the access to the variable is actually simpler, as you do not have to refer to the entity attribute). And I strongly believe that the predictability and the control around getting the latest data outweigh this one extra step.
      I often think that it would be beneficial for many beginners to figure out whether they want to stay like that - and most people do and this is fine! HA has many things to offer to them.
      Or if you need (and want) to take it to the next level. And the answer for many is no.
      I regularly watch Matt's Off-Road recovery channel, I love the craftsmanship he used to build the Banana, the Morrvair, the Wrecker, and now the Bombi. I love it....but I know I'd never be able to do things like that, Most people just buy their Jeep at the dealer (and if I did, I'd still not know how to drive it off-road). And we should think the same about Home Automation.

    • @lawrencemanning
      @lawrencemanning Před 9 měsíci +4

      @@bruxy70 What about automations though?
      I don't like this either. The advanced user is now burdened with prompting HA to get the latest forecast and managing its storage instead of this being transparent. I use the UK MetOffice and OpenWeatherMap and have never had issues with too many API calls etc. This change is a pain on many levels, not least I'm going to have to rework my ESPHome devices. And I'll see no benefits that I know of.

    • @dudefromkeene
      @dudefromkeene Před 2 měsíci +1

      I agree this is just a pain.

    • @GregWoodsLancs
      @GregWoodsLancs Před 24 dny

      @@bruxy70 I am an "intermittent intermediate". I set up my automation 2 years ago to control my home heating. I had a reasonable understanding at the time. But HA is not my hobby. So when my automation completely breaks, the learning curve is the same as 2 years ago. Everything is new. The official docs don't help at all as they are written as reference docs for those who already know HA.
      Your video is the best description of this change I've seen. Way better than the docs. But it will still take multiple hours of experimenting to work out (again) how templates and services are going to work for me.
      As an experienced user yourself, there are things you take for granted and feel no need to explain. In this video, one example is: why does the action need a target when the action's result is being pushed into a response_variable? - I'm evidently missing something.
      Anyway.... I'd better get back to it. It may be summer, but it's still cold in the UK, and Winter is Coming!

  • @DamienDavidO
    @DamienDavidO Před měsícem

    Hmm I’m very interested in getting real weather data in different origins that can control smart devices to regulate the weather in a tank to be within plus 3 or minus 3 degrees. I have a sensor to detect temps and humidity, just not sure how to create the automations.

  • @videosfromniek
    @videosfromniek Před 9 měsíci

    Hello Vaclav, can you publish your weather templates

    • @bruxy70
      @bruxy70  Před 9 měsíci +2

      I did show them in the video. There is nothing more to it. And honestly... I did these a long time ago, at the time it was dark sky, then I moved it to met.no, now I move it to the service, and it still works, and I am not going to re-engineer everything.
      But, if you start from scratch, I'd encourage you to try to figure out what you want to do and how you want to do it. Spend some time with it, try to figure it out. And I do not want you to just copy the code from me without knowing what it does. I just want to show the way :). Ok?

    • @wr3ckt
      @wr3ckt Před 2 měsíci

      @@bruxy70 ​​⁠ The open source community is a fundamentally “copy paste”-friendly one at its core due to its very nature. There’s no harm in publishing your work on github for others to leverage as it’s done everyday - and for many, it’s their way of learning from experts. By all means, an explainer would also go a long way for those which need it, but it’s not the only way to inform your audience seeking your guidance. Be patient with, and grateful for, those which seek your help- we’ve all been there.
      @videosfromniek, there’s much discussion on the Home Assistant Community site around this topic and all are more than willing to help you out- with code needed, general questions, and beyond. ❤

    • @dudefromkeene
      @dudefromkeene Před 2 měsíci +2

      @@bruxy70 I get it, you want us to learn. But in reality I'm never going to be an expert in HA. I just want things to work. I have too many other hobbies/ Jobs to do for me to deep dive even more than I already have in HA. I got 40+ vehicles to maintain, Classes to teach, 45 min assembly talks to prepare , students to supervise, wife & kids to love, and other better things to do then to jack with Home assistant.
      I simply don't want my pipes to freeze when the temperature dips. It was easy to setup before. Now it is not straight forward even after watching your video and explanation. I'm probably going to have to watch it again... Sigh....

  • @dudefromkeene
    @dudefromkeene Před 2 měsíci

    ok so I'm not getting it and I want it to make sense in my head. you call a service and get the response. but then you make a template to respond to the response that gets the forecast.
    where does the response go? where is it held while waiting?
    Why do we need two steps now instead of one for just getting the lowtemp for the night?
    what if I make a template that runs before the service. Would it grab the info from the last time you made a service call?

    • @bruxy70
      @bruxy70  Před 2 měsíci

      You do not have to make a template or call service. Just put a weather card on your dashboard and it will show everything, including daily and hourly forecast. What I was showing in the video is only if you want to make some automations.

    • @dudefromkeene
      @dudefromkeene Před 2 měsíci

      I already have the card, I need to make automatons. I wanted the heat to automatically turn on when the temperature goes below zero