
Well, they can create a law to properly fine such things in the future. If current law doesn’t allow imposing a proper fine, it’s not possible to amend in a way that allows fining after that.
At least in Finland you can only get punished according to the law that was in place when you did the act. Not any laws that were passed later. AFAIK the same is true in the US as well.
I don’t know how it goes in the US, but in Finland the concept of lex praevia is set in the Finnish constitution.
While the Finnish constitution is not set in stone, and can indeed be amended via a supermajority, there’s practically no government that would actually allow that kind of change to legislation. It’s obvious to anyone what breaking said principle would mean and strive for, and doing so would require at least four different parties to agree.