FILE - This undated photo provided by the San Francisco Police Department shows Juan Francisco Lopez-Sanchez.  It’s been two years since Kate Steinle was randomly gunned down on a busy San Francisco pier in a shooting that set off a fierce national immigration debate. Lopez-Sanchez, the man accused of killing Steinle, is still waiting for his murder trial to be scheduled. He is set to appear in court Friday, July 14, 2017, when a trial date may get set.  (San Francisco Police Department via AP, File)
FILE - This undated photo provided by the San Francisco Police Department shows Juan Francisco Lopez-Sanchez. It’s been two years since Kate Steinle was randomly gunned down on a busy San Francisco pier in a shooting that set off a fierce national immigration debate. Lopez-Sanchez, the man accused of killing Steinle, is still waiting for his murder trial to be scheduled. He is set to appear in court Friday, July 14, 2017, when a trial date may get set. (San Francisco Police Department via AP, File)

The murder trial of the man who killed Kate Steinle is inching closer to starting, two years after the fatal shooting set off a fierce immigration debate.

A judge on Friday ordered Juan Francisco Lopez-Sanchez, 54, back to court on July 21 with the hope that an open courtroom can be found in San Francisco superior court to start the trial. The suspect has waived his right to a speedy trial.

President Trump and others seized on the July 1, 2015, shooting to argue for tougher immigration enforcement and for the abolition of so-called sanctuary cities like San Francisco, which prohibits its law enforcement officials with cooperating with federal authorities on most deportation matters.

Lopez-Sanchez had been convicted five times of illegal re-entry into the United States when the San Francisco sheriff released him from jail after a minor marijuana charge was dismissed.

Lopez-Sanchez was released despite a request from federal immigration officials to detain him for possible deportation.

Lopez-Sanchez has pleaded not guilty to second-degree murder for the July 1, 2015, shooting of Steinle while she was walking with her father on a city pier crowded with tourists.

Lopez-Sanchez said he was playing with a semi-automatic handgun he found when it accidentally fired, striking Steinle in the back and piercing her heart.

He told police he found the gun wrapped in a T-shirt underneath a bench shortly before Steinle was shot. The .40-caliber SIG Sauer P226 handgun was stolen a few days earlier from the car of a Bureau of Land Management agent.

The BLM is trying to block a subpoena ordering that agent to testify at the trial, Lopez-Sanchez lawyer Matt Gonzalez said Friday, arguing that a state court can’t order a federal employee to testify.

The Department of Interior has said the lawyer must apply to the agency for permission to let the agent testify. The Department said it requires a detailed explanation for the agent’s testimony, which Gonzalez opposes because he said it could divulge his trial strategy.

A judge will decide July 21 whether to force the BLM agent to honor the subpoena for the agent’s testimony.

“His negligence started the chain of events that resulted in the gun ending up on the pier,” Gonzalez said.

Lopez-Sanchez is not charged with stealing the gun and the San Francisco police have made no arrests in the theft.

Gonzalez said his client fled extreme poverty in his native Mexico and has a second-grade education.

Jim Steinle and Liz Sullivan, the victim’s parents, declined comment through their attorney Frank Pitre.

In testimony before the Senate Judiciary Committee in 2015, Jim Steinle blamed “disjointed laws” and “basic incompetence on many levels” for his daughter’s death.

“Our family realizes the complexity of immigration laws. However, we feel strongly that some legislation should be discussed, enacted or changed to take these undocumented felons off our streets for good,” Steinle told the committee.