Unions are incentivized to bargain for as much compensation as possible and politicians are incentivized to give it to them if union workers make up a significant chunk of votes. Politicians don't have to be concerned with whether or not those obligations are realistic because they'll be out of office by the time the whole thing falls apart.