Laws and social conventions change with time.It really is sad to see or hear of another person punished for something that should have never been illegal, and then blame it on said person.
Knowingly breaking a law is knowingly breaking a law.
The speed limit on I10 in LA should be >60 or >70 MPH at points. Should people be punished for exceeding it currently even if it might change in the future? What about people who the law really shouldn't apply to? Like a guy in a nice Ferrari safely doing 95 MPH down the road at 2am when no one else is there. He's driving in a straight line and is paying attention. It's unlikely his car will have a blowout. The 70 MPH speed limit really shouldn't apply to him as that's not exactly within the merit of the law. Should he be punished for knowingly breaking the law that he is intentionally breaking, with minor risk aside from legal risk?