I ran into an angry dad from another state with stories to rival mine. He said that his wife managed to get him temporarily committed to a mental hospital at the same time that she got a restraining order against him. It turned out that these actions were in conflict! How could he be a threat to her if he was in a mental hospital? The mental hospital had to release him so that he could appear in court to contest the restraining order.
He also said that the lawyers insulate the spouses from the actual action before the judge. Some lawyers here do that figuratively, but he said that the court had actually built a wall in the courtroom so that the spouses do not see the judge and the judge does not see the spouses. The lawyers try their case before the judge, with the clients behind the wall. After the hearing, the lawyers present their deal to the clients. The lawyers explain that the clients have a right to challenge the outcome, but the judge hates it when anyone does that, and will retaliate against anyone who tries.
This isn't justice. Being able to observe your own trial is a basic human right. If a Third World country did this, I would suggest notifying Amnesty International in order to pressure them into acting in a more civilized manner. No lawyer with any integrity would even go along with such a scheme. Lawyers are supposed to advocate for their client's interest, not to make decisions for the client against his will.