I don't understand why governments let companies hardball them like thatMoral hazard [1]. Government officials make these decisions because they can win political points by doing so. Usually, they get to take credit for being “job creators.” Opposition politicians who try to raise the issue of risks, potential debts, environmental degradation, etc. can be quickly branded as anti-jobs and their valid criticisms dismissed.
Down the road, when the chickens come home to roost, the politicians who approved the deal are nowhere to be found. Since there’s no law allowing the public to hold those politicians financially accountable for their past decisions the effect of moral hazard has run its full course, leaving the public holding the bag.
As for why (even new generations of) politicians would continue to cave to these companies’ demands: no one wants to be left taking the blame for job losses.
[1] https://en.wikipedia.org/wiki/Moral_hazard