A federal appeals court judge has issued a scathing attack on the secret use by death penalty states of compounding pharmacies to supply drugs deployed in lethal injections, ridiculing the source of Wednesday morning’s execution in Missouri as possibly “nothing more than a high school chemistry class”.

Kermit Bye, a federal judge on the US court of appeals for the eighth circuit, issued his dissent just hours before Michael Taylor, 47, was executed for the 1989 murder of a 15-year-old girl, Ann Harrison, in Kansas City. Taylor was put to death using a massive dose of the sedative pentobarbital obtained by the department of corrections from a pharmacist whose identity the state refused to disclose.

The eighth circuit declined to award Taylor a stay of execution, as did the US supreme court that cleared the way for the lethal injection to go ahead. But in his dissent, Bye made one of the most impassioned arguments yet from a federal judge decrying the creeping secrecy in the practice of the death penalty in America.

He pointed out that the eighth amendment of the US constitution “prohibits the unnecessary and wanton infliction of pain through torture, barbarous methods, or methods resulting in a lingering death”. Bye then went on to argue that given “the absolute dearth of information Missouri has disclosed to this court, the ‘pharmacy’ on which Missouri relies could be nothing more than a high school chemistry class.”

He added: “I once again fear Missouri elevates the ends over the means in its rush to execute Taylor.”

Bye’s dissent was backed by two other judges on the appeals court. More significantly, three justices of the US supreme court – Ruth Bader Ginsburg, Elena Kagan and Sonia Sotomayor – also added their agreement to his searing criticism.

Missouri has become a front-line state in the battle over lethal injection drugs after the state decided to speed up the execution process. The department of corrections appears to be running a conveyor-belt system, with Taylor being the fourth prisoner put to death in as many months.

In the course of accelerating its activities, the state at first turned to the Apothecary Shoppe, an Oklahoma pharmacy that was unlicensed in Missouri to supply dangerous drugs. But after the Apothecary Shoppe agreed to close down the supply route in the face of a legal challenge, Missouri changed its protocol with less than a week to go and announced it had found another, unidentified, compounding pharmacy to make up the drug.

Bye underlined that with such a short lead-in time, there was no possibility for the pharmacy to perfect its technique or even to test the substance that it concocted. “One should be suspicious of any pharmacy compounding a drug presumably for the first time, particularly when the pharmacy received Missouri’s request just a week before the scheduled execution,” the judge wrote.

He concluded that “it is conceivable this lack of experience and knowledge would lead to Taylor’s death being excruciatingly painful”.

The focus now switches to Florida where the state is poised to execute its fifth prisoner using the sedative midazolam as an alternative to pentobarbital, supplies of which have run out across most death penalty states as a result of a European Union-led boycott. Paul Howell, 47, will be put to death with a three-drug lethal cocktail starting with midazolam on Wednesday evening for the 1992 death by bombing of a police officer, Jimmy Fulford.

Howell’s lawyers have petitioned the courts for a stay of execution on grounds that midazolam is not certain to put the prisoner so deeply asleep that he would not suffer the excruciating pain of the last of the three drugs, potassium chloride, that stops the heart. An expert in anaesthesia, Dr David Lubarsky, called to give evidence on behalf of the inmate at a hearing last week, described the impact of the potassium as feeling “like liquid fire”.

Midazolam was used in a controversial two-drug formula by Ohio state to kill Dennis McGuire last month. Eye witnesses described the procedure, in which the prisoner gasped for breath for up to 14 minutes, as horrifying and inhumane.

The first time Florida used midazolam to kill William Happ, 51, last October, the execution took about twice as long as normal under the old procedure and the prisoner was seen to blink several times during it.

The anti-death penalty group Reprieve has called on one of the main US manufacturers of midazolam, Akorn pharmaceuticals of Illinois, to place distribution restrictions on the drug that would ensure that it could not be used by departments of correction for executions. Similar controls have been successfully introduced by several other major drug companies in the wake of the European boycott.