Who was the man who died in Tripoli yesterday after a prolonged and painful battle with prostate cancer?

Was Abdelbaset Ali Mohmed al Megrahi the biggest mass murderer in Scottish criminal history? Was he the fall guy for a much wider international conspiracy than has so far been revealed? Or was he, as the Justice For Megrahi campaign claimed yesterday, "the 271st victim of Lockerbie"?

The families of those who died on that terrible night in December 1988, when "liquid fire" rained down on the quiet town in the Scottish Borders, remain bitterly divided on the issue. Certainly, most of the American relatives would subscribe to the first of those three descriptions. For them, the death must bring some relief, even satisfaction.

However, a number of the UK relatives, including retired GP Dr Jim Swire, who has campaigned tirelessly on this issue, are convinced that Megrahi was either entirely innocent or only peripherally involved. What unites them all is a need to get to the truth. For their sake, it is vital to assemble all the pieces of the jigsaw concerning this atrocity that have emerged in the following 24 years and attempt to join them together. This had not been done before and Megrahi's death makes no difference to the case for it happening.

From the outside, Megrahi's conviction in 2001 at a special Scottish court of three judges sitting at Camp Zeist in the Netherlands looked solid enough, even if most of the evidence was circumstantial. Using his job as head of airline security at Libyan Arab Airlines, Megrahi – a secret agent in Colonel Gaddafi's regime – had loaded a suitcase containing explosives hidden in a radio cassette player on to plane in Malta. The suitcase was later transferred to Pan Am flight 103 which exploded five miles above Lockerbie. Megrahi's first appeal against conviction was unanimously rejected. So by 2002 eight Scottish judges had considered this case and all believed the conviction was safe.

The Libyan's second appeal was on the basis of new evidence, after the Scottish Criminal Cases Review Commission ruled that there were six grounds for appeal. Details from the report have been printed in The Herald and the full report has been published online by our sister title the Sunday Herald. The grounds raise serious doubts about much of the forensic evidence on which the conviction relied as well as the veracity of the key witness, Tony Gauci, a Maltese shopkeeper, who is said to have been paid a substantial reward for his assistance in the investigation. Crucially, evidence that might have helped clear Megrahi was not shared with the defence. The second appeal was withdrawn when he was released on compassionate grounds in 2009, following his diagnosis of terminal prostate cancer. Regardless of whether he is innocent or guilty, there are grounds for a conclusion that he should not have been convicted and that a second appeal would have come to that conclusion.

Megrahi's death must not end the search for the truth. One option appears to be the possibility of one of the bereaved relatives taking up the appeal. Another would be for the Scottish or UK government to institute a judicial inquiry. This would be long and expensive but we cannot put a price on justice. A country can be judged by the quality of its judicial system. This case leaves a smear on the quality of Scottish justice that needs to be either contradicted or belatedly put right.

The example of the Bloody Sunday Inquiry shows that even long after the event, it is possible to put together a detailed narrative of an event that answers many outstanding questions and brings a measure of closure to the relatives of those who lost their lives. Even if Megrahi was guilty, he cannot have acted alone. If it is possible to identify those involved, they must be brought to justice. Those who in the name of some perverted political ideology would massacre innocent civilians need to know that they can run but they cannot hide.

Of course, part of the problem is that several foreign governments and groups may have had a hand in this atrocity and without regime change in those countries, they are unlikely to come clean. Early evidence pointed to a Palestinian group and both Iran and Syria have been suspected of involvement. After all, they had a motive: retaliation for the shooting down of an Iranian passenger jet by the American warship USS Vincennes in July 1988. That is no reason for not attempting to get to the bottom of what happened. In the short term, the most likely source of new information is Libya itself, where the new government has a vested interest in exposing the sins of the Gaddafi regime and any international links with other sponsors of international terrorism.

For Scottish Justice Secretary Kenny MacAskill, who took the decision to free Megrahi on compassionate grounds, this death ends more than 1000 days of political pressure. Though his decision to visit Megrahi in prison was unwise in The Herald's view, the decision to release on compassionate grounds was taken on sound medical advice. Terminally ill cancer patients often defy expert medical opinion about their likely longevity.

The Labour Party seems to have been divided on this issue and the Labour Government emerges with little credit. Including Megrahi in the scope of the prisoner transfer agreement (PTA) negotiated with the Gaddafi regime, in full knowledge that the case came under the Scottish Government, shortly before BP signed a £500 million deal with Libya, was devious. It gave Megrahi's release all the appearance of a grubby deal, even though it was not under the auspices of the PTA.

The death of Megrahi does not draw a line under this business for the grieving families of Lockerbie and the passengers of Flight 103. It merely marks the end of one chapter. In both Edinburgh and London, we need the political will to get to the bottom of this dreadful case. The only man convicted of this appalling atrocity is dead but others roam free. They must be brought to justice.