John Swinney has apologised over his handling of revived plans to introduce a named person for every child in Scotland.
The named person for every child would usually be health visitors or teachers appointed to look out for the welfare of every child in Scotland.
But the proposal has provoked anger among campaign groups who see it as an unecessary state intrusion into familiy life.
The plan was kicked outlast year by the UK Supreme Court, which found that information-sharing provisions in the legislation were incompatible with the right to privacy and family life as set out in the European Convention on Human Rights (ECHR).
The new legislation requires Scottish ministers to publish a code of practice for professionals on how information should be shared.
READ MORE: Scottish Government urged to reconsider approach to named person code of practice
Mr Swinney, who is also education secretary, told the committee that his decision to provide them with a draft and illustrative code without the necessary consultation had backfired.
He said: “I thought it would be helpful to the committee to have the look of what a code of practice might be like.
“I accept that that has created some confusion and uncertainty amongst stakeholders.”
Tory MSP Oliver Mundell asked how confident the government was about the legislation withstanding another legal challenge, and whether Mr Swinney would “take personal responsibility and consider your own position if this legislation falls apart?”
Mr Swinney said he approached his ministerial responsibilities “in a deadly serious fashion”.
He said: “I’ve come to the committee this morning and I’ve been quite candid about a misjudgment that I have made about giving the committee a code of practice that was draft.
“It has created more confusion and I didn’t want to do that and I’m sorry that that’s the case, that the committee has had quite a bit of its time taken up by the debate around a code of practice which actually isn’t the subject and the question that the committee is being asked.
“But in coming to the committee with the bill, I’ve taken all the necessary advice that I need to take to satisfy me in my judgment that the two issues of proportionality and codification have been addressed in the bill, but, as I say, if there’s a legal challenge the courts will determine that.”
Setting out further steps to offer more “certainty and clarity”,
Mr Swinney said an expert panel with an independent chair would be established to ensure the code is “workable, comprehensive and user-friendly”.
The government will also lead a positive awareness-raising campaign about the named person scheme and will commit further financial resources “to assist implementation beyond the first year of introduction”, he said.
Mr Swinney also confirmed he would amend the bill to give MSPs final approval of the code of practice.
Mr Swinney wrote to the committee earlier this week and confirmed the Scottish Parliament will be given final approval on the code which will start from a “blank sheet of paper”.
Concerns over the proposed code of practice had previously been considered by Holyrood’s delegated powers and law reform committee, which concluded the code was “more than simply an explanatory document” and highlighted other examples of codes of practice which had been brought forward by way of subordinate legislation.