(Updates throughout.)

Concern was rising among some anxiously-waiting parents outside Midlothian High School as a lockdown of the school stretched well into the afternoon. But in the end, no threat was found and everyone emerged safely.

A five-hour lockdown of the high school was finally lifted after Midlothian police officers searched the school.

“After a thorough investigation, the Midlothian Police Department has given MHS the all-clear and the lockdown has been lifted,” Midlothian Independent School District said in an updated Facebook post at 2:37 p.m.

The campus dismissed at the normal time, and all extracurricular activities proceeded as scheduled Friday night.

Police went from classroom to classroom, searching students and backpacks, after school officials were alerted to a possible threat at about 9:30 a.m. The district said two high school students shared a possible threat with campus administrators. According to a Midlothian PD statement, a student witness stated they observed another student display what she believed to be a handgun.

”In MISD, we take all threats seriously and MHS immediately put the campus on lockdown,” district superintendent Lane Ledbetter said in a separate statement. “We always encourage our students if they see or hear something to say something. These two students did just that — reported what they thought they saw and heard.”

A unified command post was set up at the MISD administration building with representatives from MISD, MPD and Midlothian Fire Rescue; and responding officers secured the perimeter and hallways of the school. In its statement, MPD said the Southern Regional Response Group’s “Special Response Team” was called to assist officers in doing a complete search of the high school.

In the statement, Ledbetter refuted rumors on social media that Midlothian Police Department had found several guns and made several arrests. “All of these statements are rumors,” he said.

The MPD confirmed that no arrests were made and no handguns or rifles were found during the search, but officers did locate some small pocketknives that were not related to the incident.

While the investigation was ongoing, school officials and police did not announce any details, but the school tweeted that all students and staff were safe.

“The MPD and District are following all proactive threat assessment protocols and procedures,” MHS tweeted.

Parents were asked to stay away from the school until the investigation was complete. Traffic was being diverted away from the school. But a number of parents congregated nearby to wait for news.

During the lengthy lockdown, Lizbeth Aguirro was one of the parents at the school waiting outside to pick up her daughter.

“I’m so scared here,” Aguirro said. “I’m waiting here more than an hour already, but we can’t do nothing about it. The only way I can contact her is by texting because I can’t even call her. They don't let her answer the phone, but every minute, I text with her. She’s safe, everybody is safe in there. That’s what she told me but we are scared still."

Similarly, Veronica Gonzalez, whose daughter attends the school, described her harrowing experience as she waited for the lockdown to end.

"She just gave me a call back right now, but wasn't having any signal,” Gonzalez said. “She's OK, she's just, anxiety. She needs to use the restroom and they're making them pee in buckets....

“I've been here an hour and a half. Very worried. I'm stressing. I have anxiety myself. I'm just trying to find something. I don't understand why they can't tell us there's a gun involved. The MISD hasn't told us anything about that and there's guns involved. I don't know why they're keeping it from us."

Jade Laswells, a teacher at another district, had been waiting for two hours but had already been communicating with her daughter and wasn’t worried.

"She's fine,” Laswells said. “She told me that they're on lockdown and that they're all safe. The SWAT team has come room by room, and searched every kid and searched every bag. They're searching the teachers, they're searching everybody, but she's safe."

Assisting MPD in the investigation were the Texas Department of Public Safety and Ellis County Sheriff’s Office, as well as police departments from Waxahachie, Grand Prairie, Red Oak ISD, Glenn Heights, Cedar Hill and Highland Park.

“The safety of the students and staff was our priority,” MPD said in its statement. “Today’s event emphasized the cooperation between all of the responding agencies to keep our students safe.”

Reporter Patrick Clarke contributed to this story from Midlothian.