17:33

The Scottish government has scrapped one of its headline policies, its controversial “named person” scheme, only a few days after bowing to opposition demands for an inquiry into two botched hospital projects.

Its sharp reversals in two key areas on which the Scottish National party government was refusing to budge until now suggests the SNP is shoring up its policy programme in preparation for a general election.

The named person scheme, a programme where every child had a designated adult such as a headteacher to safeguard their welfare, has been dubbed a “snooper’s charter” by critics, partly since families might have no idea they were under scrutiny.

The Scottish government went all the way to the UK supreme court to defend the policy, where judges said its aim was benign but it breached the right to privacy and family life under the European convention on human rights.

It was due to be introduced three years ago. John Swinney, the education secretary, told Holyrood he had now scrapped it entirely.

Two days ago, Jeane Freeman, the health secretary, announced an independent public inquiry into the handling of contracts to build the Queen Elizabeth super-hospital in Glasgow, where two children died earlier this year, and the new Royal Hospital for Sick Children, which will open several years late next year.

With both measures, the temporary pain of a climbdown neutralises two potentially damaging lines of opposition attack in an election.