No hope. In all this time since the issue/topic was opened, (to my knowledge) only one user wrote some Python code, it worked partly for me. You could try it: https://github.com/home-assistant/architecture/issues/230#issuecomment-600484354
Another appeal to vote for the feature request to help on this: Retain last state change data of a sensor after reboot
Just stumbled upon this and I’m really sad to head that this basic functionality is missing in Home Assistant. Coming from openHAB myself this seems like a rather big showstopper 
Paulus we need an option to populate last_changed state machine values from the history database. With the flourishing of the platform, and high frequency of updates, restarting Home Assistant is now a common and regular occurrence for most
The amazing thing about Home Assistant is that about 85% of it is this incredible combination of insanely powerful and flexible functionality. Incomparable. The other 15% is a combination of foundational features that work in the least useful way possible or are missing altogether. If you dream something up, you can get 85% of the way there intuitively and reliably. And that last 15% where you’d expect to flip the ‘on’ switch, you will spend hours reading posts in disbelief that it’s just been broken for 8 years. And the devs are like 'You know what people want? 85% of another feature".
Home Assistant works, absolutely. And there are things that work well. Like the Integrations, the Add-ons, the YAML config, etc. Unfortunately the Home Automation side frankly just doesn’t.
Here’s an example: I want to scan an NFC tag, and send a notification to the device that scanned it after e.g., 1 hour (for my laundry). NFC tags work great! And notifications work great! But there is no supported way to combine those two things. I wish the devs would spend a year or so just making the existing features work well together. It would avoid wasting so much time and people could go so much more done without spending 50% or more of the time working around dead basic stuff that is just MIA.