France, July 17 -- The boy, who was 14 at the time of the attack, has been held in custody for the past 13 months.

As a minor, he faced a maximum sentence of 20 years.

During a two-day hearing in the town of Chaumont, prosecutors argued he should be held fully responsible.

But the court ruled that his judgement had been impaired at the time because he was suffering from a "persecutory delusion", the presiding judge said.

However, the court refused to reduce his sentence because of the "extreme seriousness" of the crime and because he had shown "no empathy, remorse or regret".

It also ordered 10 years of judicial supervision after his release, including compulsory psychiatric treatment.

Teenage pupil faces murder charge after school ...