1) no pandemic, no action -> government was "right", avoided wasting money -> reelected
2) no pandemic, action -> government was "wrong", wasted a lot of money, damaged the economy, inconvenienced the lives of the population -> voted out
3) pandemic, no action -> government was "wrong", caused loss of lives and damaged the economy -> voted out
4) pandemic, action - this is the trickiest scenario, so let's consider two options:
4a) pandemic, action, it works -> government was "right", saved lives, spared the economy -> reelected
4b) pandemic, action, doesn't work -> government was "wrong", their actions failed, they're incompetent -> voted out
There's two winning scenarios, (1) and (4a), but the problem is that (4a) has vanishingly small probability of success... with little information available about the virus, and rampant globalization, it's hard to know what action makes sense, is correct and viable... Case in point is Italy, which did act in time (they banned flights from China 2 weeks before the outbreak), but still failed (i.e. their action was "correct" but not "correct enough") because their neighboring countries (e.g. Germany - not technically a neighbor but within Schengen Zone) failed to act.
So, politicians choose (1), no action, as the most likely winning scenario.