The government had tried to please the left and right with a carrot-and-stick approach that would have sped up the expulsion of illegal migrants while making it easier to obtain residency permits for those who work in sectors in high need of workers, whether it be to work in a restaurant or take part in harvests.