The city is conducting an investigation into the D.C. fire department response last week to a 911 call to help a toddler who was choking on grapes and later died.

Paramedics who were about a mile away were sent to the child’s Tenleytown house on March 13, while others only blocks away were never dispatched. The boy, about 18 months old, died Thursday, officials said.

Kevin Donahue, the deputy city administrator, said an investigation is underway to pinpoint failures. The city blames the delay on human error, while the firefighter’s union says it was caused by problems with technology used to identify fire engines and ambulances closest to emergencies.

A paramedic first arrived about 7 minutes after the 911 call — at the outer end of the accepted response time.

“We’re going to leave no stone unturned,” Donahue said. “If there is anything we could have done differently or done better, we’re going to identify is and fix it. We’re in a no margin-of-error business.”

The Fox affiliate, WBFF-TV, first reported the response. The name of the child has not been disclosed.

The incident occurred in a house on Warren Street, three blocks off Wisconsin Avenue, where Engine 20 is based. The first 911 call was received at 8:40 a.m., officials said. Donahue said the firefighters at Engine 20 had not properly signed into a computer program used to track which units are available and where they are.

“The closest paramedic unit the computer saw was a mile away,” Donahue said.

A dispatcher sent Engine 31 from Connecticut Avenue, which arrived at 8:47 a.m., officials said. A truck company and another medic unit followed one and two minutes later. The child was rushed to a hospital, where he died six days later.

Donahue said it might never be known whether the boy would have survived had Engine 20 arrived a few minutes earlier. He noted that the paramedic who did respond is an expert in pediatric emergency care.

The death is the one in a series of problems this month in the departments’ response to medical emergencies, including an injured D.C. police officer and a stabbing victim who each waited 20 to 30 minutes for an ambulance. Those waits were attributed to an overwhelming number of medical emergencies, but they also indicate that problems of the past persist and will be a challenge to the new fire chief, Gregory Dean, who is set to take over May 1.

Mayor Muriel E. Bowser, who took office in January, inherited a fire department criticized for slow response times, broken equipment and a shortage of paramedics, with the union and the previous administration fighting over fault. Response times came into sharp focus well before Bowser became mayor. In January 2014, Medric Cecil Mills Jr., 77, collapsed across the street from a fire station and died after he was refused help from the firefighters inside. A 71-year-old man died of a heart attack on New Year’s Day 2013 after waiting more than 30 minutes for an ambulance.

Donahue said the investigation centers on both the adequacies of the computer system — which the union says has had problems — and the actions of the firefighters assigned to Engine 20 to determine whether they were negligent in failing to properly log on to the network. Also under review, he said, is whether those firefighters heard the call go out and should have notified superiors that they might be closer to the call.

Edward Smith, president of Local 36 of the firefighters union, said authorities need “to figure out what went wrong and where.” He said that if firefighters in the closer station heard the call but did not react, it might be because they assumed the other engine was on the street and nearby. “We’re supposed to have trust in the system that it’s picking the closest unit,” Smith said.

Public Safety Committee Chairman Kenyan R. McDuffie (D-Ward 5), said he wants to know whether the failure involving the child “is an isolated event or a systematic problem.” He said firefighters will now be able to call dispatchers by phone to tell them they’re available for calls, as a backup.

“I can’t begin to imagine the pain that this family is going through,” McDuffie said. “We have to make sure there are systems and protocols in place to keep it from happening again.”