It was only through a large dose of luck and a little cleverness that Jacinda Ardern dodged political disaster this week.
Tuesday could easily have been her worst day as PM, at least of her second term.
On top of power blackouts in the middle of winter for thousands of Kiwi homes on Monday, we could so easily have had Delta silently infecting Tauranga for the past few days after 72 port workers - a pitifully low number of them vaccinated - boarded a Covid-19 contaminated container ship Rio De La Plata.
Besides the gravity of these two massive problems, they both involve Ardern's most competent ministers, Energy Minister Megan Woods and Covid-19 Response Minister Chris Hipkins.
And they are about failures to deliver the absolute basics, heat and light in winter, and border systems to keep out Covid.
Ardern's first instinct on Tuesday morning was to get ahead of the public outrage.
Megan Woods was explaining some of the technical background to journalists about the emergency alert sent by Transpower on Monday to the country's generators when Ardern took over.
Ardern was addressing the public unnerved by the blackouts and wondering if it was a failure of Government. She said what had happened was unacceptable, and the Government was demanding answers about whether it could have been preventable.
Ardern was on the offensive, not the defensive, and it was the politically smart choice, to be more outraged than the public while the Government sought answers.
The negative Covid-19 test results for 109 workers tested at the Port of Tauranga were sheer luck. Ardern and Hipkins take umbrage at the suggestion that luck plays any part in New Zealand's management of the borders.
But what else do you call a narrow escape when so few Tauranga port workers are vaccinated?
There are still many unanswered questions from both problems, and there is still plenty of room for the Opposition to point the finger at the Government. Tauranga Port clearly needs extra special attention by the Government, much more than it has been given.
And so does security of energy policy.
Woods has essentially blamed a commercial decision by Genesis and "the market" for the power crisis, but it is a bit rich for a government in its fourth year to blame Max Bradford's reforms of the 1990s.
Blame cannot be put in a time machine. If Transpower issues an emergency alert to generators about capacity, as it did on Monday, the Government needs to have ensured it has the power to require, not the power to request. That is a current failure.
And it is not acceptable for the minister to find out there is a capacity issue at 8.30 pm on Monday when the first cuts were made at 6 pm and when Transpower had sent out a notice to major generators at 6.43am that their forecasts were in deficit.
Labour's sudden decision to ban new oil and gas exploration in 2018 without having campaigned on it is not connected to Monday's blackouts. But that won't stop the Opposition making some kind of connection. It is a gift for National.
National had one of the worst conferences in recent years at the weekend. Most stories about it were about divisions. The party looked weaker after the conference than before it.
Within a day, Judith Collins, a former Energy Minister, suddenly sounded competent rather than a dysfunctional leader of a dysfunctional party. It was her best day in a long time.