Garvan Walshe is a former national and international security policy adviser to the Conservative Party.

The sight of an EU member state standing up for the integrity of its legal system against the Court of Justice in Luxembourg should bring cheer to most readers of this site. The Polish government wants you to see last week’s ruling, issued from the bench at its Constitutional Tribunal, as a clash between legal systems. “Who runs Poland?” they hope to ask, “you or the EU?”

It is an attractive case, and would have without question provided material rousing Conference speech at Manchester, but doesn’t come out well from an encounter with Polish political, let alone legal, reality.

Since coming to power in 2015, the Law and Justice-led government in Poland has been at war with the country’s institutions. It has appointed political placemen to run state-owned companies, turned the public TV into a grotesque propaganda outlet (most recently showing a Government minister displaying a bestiality video that it falsely claimed was found on a migrant’s phone). It has sought to exclude the independent TVN news channel, which is owned by Discovery, from the broadcast market.

The chief target of its campaign, has been, however the judiciary, which it sought to purge by reducing the retirement age for judges, and to which it appointed former Communist-era prosecutor Stanislaw Piotrovicz. It sought to make it difficult for the Constitutional Tribunal to strike laws down by amending the Tribunal’s rules of procedure. When the Tribunal ruled these changes unconstitutional, it exploited a loophole in Polish law which renders judgements void until they are published to prevent the court’s striking down from going into effect.

It then turned to the other courts, and sought to control judges by reassigning, docking the pay, and even prosecuting Igor Tuleya, a Warsaw District Cout Judge, for allowing a public hearing to be recorded.The regime under which he was brought to book is one of several aspects of Law and Justice’s attack on the judiciary that have become the subject of litigation at the ECJ.

In the intervening time, the make-up of the body that sits in the building adorned with the plaque “Tribunal Konstituticzny” has changed. Using rules struck down by the court, but whose striking down was disobeyed by the exeuctive branch, the government has been able to appoint a majority of friendly judges to the bench. Strictly speaking, therefore, this new “Tribunal Konstituiczny” has been improperly constituted, and its rulings are consequently invalid.

Meanwhile the ECJ ruled that the EU’s founding treaties require judges to be independent, and that Law and Justice’s measures have put undue pressure on the judiciary. This set up the latest confrontation, whereby the pro-Government Tribunal, declared the Polish constitution to be superior to EU law, a claim completely inconsistent with EU law.

As a matter of domestic law, this flies in the face of the plain meaning of the Polish Constitution, which allows “ratified international agreements” to be a source of law (Article 87), and delegate powers to an international organisation by a two thirds parliamentary majority (Article 90) and that “a ratified international agreement shall constitute part of the domestic legal order” (Article 91).

As a matter of international legal dispute, the Polish ruling goes much further than that of the German constitutional court, by asserting the superiority of (its quixotic interpretation) of the Polish constitution, not only to acts of an EU agency, as the German court claimed, but to the EU’s fundamental treaties.

The stage is now set for a power struggle, between a Polish government that rejects the most basic premise of EU membership, and a European Union that considers the Polish ruling against it not only to be invalid, but to have been issued by a court that is itself illegitimate.

It is a power struggle in which the EU holds two very crucial cards: money and public opinion. Poland is a net beneficiary of the EU budget, which means that the EU can simply deduct the fines its courts impose on Poland for failing to uphold the EU legal order from the fiscal transfers it would otherwise be owed. Poland’s share of the post-Covid “recovery and resilience fund” (RRF), already delayed due to Poland’s previous rule of law deficiencies, is hardly going to be disbursed now. That Poland spent Monday and Tuesday arguing in front of the ECJ that the regulation making the RRF funds subject to rule of law criteria was inconsistent with the very EU law whose legitimacy it rejects will not add to Warsaw’s credibility.

Nor is public opinion on the Polish government’s side. EU membership is extremely popular in Poland, with around 90 per cent support even among Law and Justice’s own supporters because it is associated with economic development and diplomatic and political security. Indeed, Poles are motivated above all by a sense that Poland ought to be considered one of the major nations of Europe, and belong to the same club as Germany, France, Italy and Spain. The alternative, belonging to the same club as Russia, is rather less appealing.

Jaroslaw Kaczynski, the Law and Justice leader, and the power behind the nominal Prime Minister, Matteusz Morawiecki, has picked what would at any time be a very unwise battle with Brussels and his own people. It is even less timely as Vladimir Putin gets ready to put the gas squeeze on Europe.

The founder of modern Poland, Joszef Pilsudski, wrote in his famous last testament that the overriding priority for his successor should be to avoid a war on two fronts. Kacynski seems determined to fight on three at once.