A US judge is set to rule on whether one of the youngest detainees at the US Guantanamo Bay detention centre should be released.
A US judge has ordered the release of one of the youngest detainees at the US detention centre in Guantanamo Bay.
Lawyers for Mohammed Jawad told the BBC they were confident their client would be set free at the hearing.
US District Court Judge Ellen Huvelle said Mohammed Jawad would be released by late August.
Mr Jawad was between 12 and 17 years old when he was arrested in 2002 in Afghanistan and taken to Guantanamo.
Mr Jawad, who was between 12 and 17 years old when he was arrested in Afghanistan in 2002, is expected to return home.
He was accused of injuring two US soldiers and their interpreter by throwing a grenade at their vehicle.
He had been accused of injuring two US soldiers and their interpreter by throwing a grenade at their vehicle.
Earlier this month, US officials said there was no military case for Mr Jawad's continued detention.
Mr Jawad's lawyer, Jonathan Haretz, told the BBC he was "cautiously optimistic" his client would be set free and allowed to return home to Afghanistan after Thursday's hearing.
"I feel we're closer than we've been but the [US] government is still taking what we think is too long to release Mr Jawad and has made noises that it's trying to get out from under the proceeding and avoid the habeas (corpus) hearing that was coming up," he said.
MOHAMMED JAWAD Charged in Afghanistan in December 2002 for allegedly attacking a US military jeepClaims his confession was obtained using tortureUS government's case against him described by a judge as "riddled with holes"
Government lawyers had said they wished to keep Mr Jawad in detention to give them time to build a criminal case against him which could see him being prosecuted in a US courtroom.
Mr Hafetz said this would be "another traumatising experience" for Mr Jawad and that the "nightmare will continue for no good reason".
"They've not produced any evidence so far and enough is enough. It's time for Mr Jawad to go home," he said.
The Afghan government has requested that he be sent home and in October 2008, a US military judge ruled confessions Mr Jawad had made were inadmissible because they were obtained under torture.
In July this year, Judge Ellen Huvelle described the US government's case against Mr Jawad as "an outrage" that was "riddled with holes".
Observers say that if Mr Jawad is returned to Afghanistan it could mean that other Guantanamo detainees will also be released.
Shortly after entering the White House, US President Barack Obama pledged to close the prison at Guantanamo Bay.
Since making the pledge, administration officials have been reviewing the case files of Guantanamo detainees in an attempt to determine which prisoners should face criminal trials, which should face military commissions, which should be released and which can neither be tried nor released.
Mr Obama has said he wants the camp to be closed by January 2010.