Advocates for inmates and psychiatric patients filed separate court actions Thursday that sought the release of some mentally ill people from District facilities and detainees at the city’s only halfway house for men because of the coronavirus.

On Wednesday, D.C. health officials announced that one patient and five staff members at St. Elizabeths, the District’s public psychiatric hospital, tested positive for coronavirus, and 22 additional staffers were quarantined. The outbreak occurred in a section of the hospital where some patients are housed for competency restoration so they can participate in court proceedings.

On Thursday, the city’s Public Defender Service filed an emergency motion in D.C. Superior Court seeking the release of those charged with misdemeanors who are undergoing competency proceedings anywhere they are housed in the District, including St. Elizabeths and the D.C. jail in Southeast Washington.

The suit noted positive cases at St. Elizabeths as well as at the jail, saying outbreaks of covid-19 “are far from speculative — they are imminent, with confirmed positive cases [at the jail] now approaching double digits.”

These defendants are “undergoing a range of competency proceedings that currently serve no significant purpose” amid coronavirus-related court closures “because their trials have been suspended essentially indefinitely, and at a minimum for a significant number of months,” according to the suit.

Laura E. Hankins, the Public Defender Service’s general counsel, said the agency filed the motion because making the jail and the attached Correctional Treatment Facility “safer places — with fewer people, more space for social distancing, and better hygiene — is better for our clients, DOC staff, our attorneys who still work in these facilities, and for all of D.C.”

City officials did not return a request for comment Thursday.

In other litigation, two people detained at the Hope Village halfway house, a contract facility for the Federal Bureau of Prisons, brought a federal class-action lawsuit seeking the release of some residents to home confinement to protect them from covid-19.

The lawsuit claimed “conditions in Hope Village facilities disregard all medical and public health directives for risk mitigation,” with no medical staff on site or space to isolate individuals with symptoms, among other problems.

“Hope Village does not encourage or practice social distancing in its facilities,” according to the complaint. “Furthermore, the structure and layout of Hope Village makes social distancing impossible.”

The suit seeks an injunction to force the halfway house to stop admitting new residents, improve hygiene and “release enough people such that the remaining people can be housed safely and in compliance with CDC guidance,” among other relief.

The Washington Lawyers’ Committee for Civil Rights and Urban Affairs and the ACLU of the District of Columbia were among advocates representing the plaintiffs in the case, filed in U.S. District Court for the District of Columbia one week after D.C. Council member Charles Allen (D-Ward 6) asked the Bureau of Prisons to provide halfway house residents with supplies and release as many as possible to home confinement amid the coronavirus crisis.

In a letter to Bureau of Prisons Assistant Director Hugh J. Hurwitz, Allen said Hope Village had ended “all non-emergency movement” of residents on March 20, “effectively terminating most residents’ employment and immediately isolating them in the facility without access to income.”

“Without immediate action, a severe outbreak of COVID-19 in Hope Village and the District’s other [residential reentry centers] is inevitable,” the letter said.

In a statement, Jonathan Smith, executive director of the Washington Lawyers’ Committee, said Hope Village residents are “very low custody” and regularly left the facility to work, attend classes or visit family before the lockdown. Most will be released within months, he said.

“There can be no reasonable argument justifying their continued confinement in light of the risk of catastrophe that it poses,” he said.

Hope Village did not respond to a request for comment. The Bureau of Prisons declined to comment.