I agree that we need a sensible and fair law. I don't know what it is and it will be tough to craft one.
However I have a modest proposal; let's take the money that some are proposing for building a 1000 mile long 18 foot high fence and vastly more border guards and spend it instead on improving the Mexican economy. It has already improved significantly along the US border and is starting to roll south from this once poorest part of the country. I don't mean welfare or such, I mean well thought out economic incentives, capitalism at its best. Of course this presumes that we're smart enough to do it right.
For too much of history, the only way Latin America could get any attention or money from us was by finding a few leftist guerrillas in the
hills. Then US $ would pour into the pockets of whatever brutal dictator was in power, to be spent on weapons. There should be a better way.