A Pennsylvania appeals court on Thursday rejected Philadelphia’s most recent attempt to overturn a state law that prevents the city from enacting its own gun regulations.

In a 3-2 decision, a majority-Republican panel of the Commonwealth Court voted along party lines to uphold the state’s firearms preemption statues, which were challenged by Philadelphia, the advocacy group CeaseFire PA, and a group of individual plaintiffs.

» READ MORE: The Texas shooter was bullied. That has Philly’s gun violence experts talking about ‘unaddressed pain’

The ruling comes two days after a gunman killed 19 children and two teachers at an elementary school in Uvalde, Texas, and two weeks after 10 Black people were shot to death in a Buffalo, N.Y., supermarket in a massacre that was reportedly motivated by a racist conspiracy theory.

Those mass shootings have reignited a national debate over gun control. But the instances of gun violence that are most relevant to the preemption case are the daily shootings in Philadelphia and other Pennsylvania cities that disproportionately impact Black and brown residents.

» READ MORE: Exploring the city's rising gun violence and homicides.

The plaintiffs argued in part that by declining to pass firearms regulations amid widespread gun violence and prohibiting local governments from doing so, the GOP-controlled state General Assembly has violated Black and brown Pennsylvanians’ right to “life and liberty” that is enshrined in the state constitution.

Judge Patricia A. McCullough, however, wrote in the majority opinion that the state Supreme Court has in the past been clear that the General Assembly has the right to preempt cities on gun laws.

She also rejected an argument about the need to pass gun control measures to protect public health, writing that “gun regulation does not directly affect the health of the people in the medical sense, such as when a communicable disease is introduced into the public, or unsanitary conditions [exist] in the streets or other infrastructure, or food products contaminated with harmful bacteria enter the marketplace.”

Mayor Jim Kenney said that the city “will most likely appeal” the case to the state Supreme Court, which has a 5-2 Democratic majority.

“We’re incredibly disappointed that the [Commonwealth] Court has again refused to allow the City the authority to help address the gun violence crisis that is devastating the City, Commonwealth and nation,” Kenney said in a statement. “With dereliction of duty by so many in the General Assembly to even pass the most minimal of gun safety rules, we feel strongly that the firearm preemption laws are unconstitutional.”

City Council has played a major role in pushing for the legal challenge to the preemption law. Council President Darrell L. Clarke said Thursday that he expected it would need to reach the high court.

“We always expected we would be arguing the case for Philadelphia residents’ constitutional rights to be free of uncontrolled gun violence in the state Supreme Court, and that’s where this case is now headed in all likelihood,” he said.

The city has tried unsuccessfully in the past to enact gun regulations such as a requirement that firearms owners notify authorities if their weapons are lost or stolen, a measure designed to prevent legally purchased guns from falling into the hands of criminals. The Commonwealth Court in February ruled that Philadelphia cannot enforce its “lost or stolen” ordinance in a case that the city has said it is appealing to the Supreme Court.

Adam Garber, executive director of CeaseFire PA, said he was disappointed but not surprised by Thursday’s Commonwealth Court ruling. He noted that Judge Renée Cohn Jubelirer, one of the Republicans who voted to uphold the state preemption laws, wrote a concurring opinion that called for the state Supreme Court to weigh in, which Garber cast as “recognizing that firearm prevention should be revisited and reevaluated and that Pennsylvanians’ right to life and liberty should be considered.”

Jubelirer then said that the “novel constitutional arguments” presented in the case may warrant the high court to revisit the issue. But until then, she wrote, the law is clear.

“Petitioners’ allegations regarding the prevalence and severity of gun violence in certain areas of the Commonwealth of Pennsylvania, and the tragic toll such violence has on the lives of those who reside in those areas, are not lost on me,” Jubelirer wrote. “However, I believe that the Court is controlled by precedent, and that our Supreme Court left little air in its conclusion ... that the regulation of firearms is to be done at the state, not local, level.”

Judge Ellen Ceisler wrote the dissenting opinion, noting that circumstances have changed dramatically since the Supreme Court’s 1996 Ortiz v. Commonwealth decision, the main legal precedent cited by the majority in rejecting the plaintiffs’ case.

“In the nearly three decades since that decision, gun violence in our Commonwealth has skyrocketed, increasing exponentially in the past few years alone,” Ceisler wrote. “Allowing local municipalities to adopt more stringent regulations to protect their residents from gun violence is becoming an increasingly urgent matter.”