US Democratic and Republican lawmakers have put an end to a spending impasse after 43 days of federal government shutdown.