Re: It's not the judge's fault
So what happens if every judge stands up and says - "I refuse to try a case with such an obviously bad law"?
Then that judge would be excused and another judge who *is* prepared to apply the law is substituted. It would be a bad thing because eventually all the reasonable judges would be forced to resign, leaving only the hard-liner establishment lackeys.
The correct and legal way for a judge to show that s/he disagrees with the law would be to find the defendant guilty as required, but then impose a ridiculously lenient sentence - e.g. a conditional or absolute discharge. No doubt the prosecution would then appeal the sentence (which will take a while, by which time the defendant may well have left the country).
However a *jury* can decide that the law is wrong and refuse to convict no matter what the evidence. The only way that could be prevented is to not allow jury trials.