We all believe in freedom of speech. But freedom of speech must be exercised responsibly. Last Thursday’s judgment from the high court on article 50 led to artificial hysteria in many quarters. There were headlines declaring that the judges who heard the case were “Enemies of the people”; references alluding to the sexuality of a judge briefly appeared on the Daily Mail’s website; and a member of the cabinet, Sajid Javid, ominously stated that “This is an attempt to frustrate the will of the British people and it is unacceptable”.

Many have said that those headlines and comments “crossed the line”. And in our constitution, when judicial independence is threatened, the lord chancellor has a legal duty to intervene. Liz Truss, however, failed to say anything for nearly 48 hours and when she did, she simply recited the principle of the independence of the judiciary and stated the government would be appealing against the judgment. She did not condemn the fact that our judges had been declared “enemies of the people”, nor that the sexuality of a judge had been introduced in to the debate.

When Truss took office she swore an oath to uphold the independence of the judiciary and the rule of law. In her speech that day she committed to doing so “with dedication”. The headlines which appeared in a number of newspapers the day after the high court ruling in the article 50 case was the first test of her commitment. On any reasonable measure, she failed that test.

That’s not just my view. The former lord chief justice, Lord Judge, was interviewed on Radio 4 on Sunday and said this: “The lord chancellor has a specific function and in this case her responsibility, where there has been vituperative criticism of judges, damaging to public confidence in the administration of justice by an independent judiciary, is to speak up for them and explain exactly what the principles are.”

For many in the legal community, studied silence on this matter means a lord chancellor loses their trust

He went on to say about Truss’s response to the attacks: “I think it was a little too late and I think it’s quite a lot too little. Because it doesn’t actually address the damage to public confidence consequent on [these] kind of headlines.”

During my 10 years as a lawyer before being elected to parliament and then becoming shadow lord chancellor, there were occasions when I disagreed with – or was disappointed with – judges’ decisions. When I lost a case, I was disappointed. When I won a case, the lawyer on the other side was disappointed. But we would never tolerate our judiciary being declared as “against the people” or a judge’s sexuality being brought into the debate.

Anyone is free to disagree with a judge’s decision, their reasoning – or lack of it – or their interpretation of the law. But what is surely unacceptable is attacks on the independence of the judiciary by government ministers and powerful government-backing newspapers. The lord chancellor has a duty to act in these circumstances and she failed.

It took a bar council resolution demanding action to draw her into the open. And then she provided a statement carefully crafted to say as little as possible, which has only attracted further criticism. And since then she has remained out of sight. Conservative MPs mindful of the rule of law have criticised her publicly and, reportedly, privately, at a fractious meeting of Tory MPs at which she is supposed to have said that it is the job of the lord chief justice to defend the judiciary. Actually, it is Truss’s statutory responsibility – and the lord chief justice is one of the judges who heard the case and is being maligned.

I know Truss has a lot on, given the crisis of violence and underfunding that has developed in our prison service, but for many in the legal community, studied silence on this specific matter means a lord chancellor loses their trust and confidence. Her failure to speak out has consequences: only yesterday afternoon, during a debate on Brexit in the Commons, David Davis repeatedly failed to condemn the headlines when asked. Other MPs have spoken about the judiciary “interfering between parliament and the executive”.

Whether it’s respecting the outcome of referendums (even when the result disappoints the Labour party) or defending the independence of the judiciary, Labour is the party of the rule of law. A mature democracy – and a mature government – doesn’t stand by while the judiciary gets a roasting.