Coal is a different thing. That said, I think that it's not necessary to have very cheap coal and oil energy to have technological advances.
https://www.factcheck.org/2017/04/facts-fracking-chemical-di...
Where I live is a perfect microcosm of this - in the summer, we get ample power from our solar array, but in the winter, when it can be dark and raining for weeks on end, it doesn’t come close - so I’m building out hydro and wind, as when it rains, a stream appears that we can harness, and the wind blows.
The same applies to renewables at grid scale - overdependence on a single source is absolutely risky, which is why most renewable energy efforts involve quite a bit of diversification.
“It can't work if you do it that way" is a pretty bad argument if nobody actually does it that way. Maybe you are accidentally misrepresenting reality in order to support your world view here, but if not please go somewhere else, where facts don't matter.
As others mentioned: every nation that does renewables is looking into robust energy mixes and this (at least in industrial nations) includes catastrophic scenarios as well).
If there was no sun at all, do you think the temperatures would only drop 1-3° as mentioned in the article?
Effectively the time when it is useful is "when we don't have cheaper alternatives yet". We still should strive to make renewables and storage the cheaper option though.
To get really pedantic our 20th century understanding of power and energy are exactly backwards colloquially from what is really provided. Power is energy over time. The "power" infastructure was actually largely an energy infastructure with the exception of say hydro electric dams - you can only burn fuel once no matter how clever your ability to extract it. Meanwhile "renewable energy" provides power over its period of existence.