GRINDSTONE, Pa.—A 17-year-old western Pennsylvania boy has pleaded guilty to attempted homicide and aggravated assault for shooting a then-7-year-old boy in the chest at a playground last year.

Fayette County prosecutors refused to move the case against Deago Eddings to juvenile court because of his significant criminal past, including a threat to kill a fellow student at school.

Eddings, of Connellsville, was 16 when the victim was engaging involved in horseplay with other children near a public housing complex in Redstone Township on July 3, 2012.

That's when Eddings shot little Amarr-e (ah-MAR'-ee) Williams, then 7, in the chest. Eddings and prosecutors have yet to explain the shooting.

Eddings remains jailed until his sentencing Dec. 16, when prosecutors have agreed to recommend eight to 20 years in prison.