In 2014, Maryland decriminalized simple possession of under 10 grams of marijuana — but in the following three years Baltimore police arrested 1,448 adults and 66 juveniles for marijuana possession. Of those arrested, 96 percent were black.

Last week, Baltimore State’s Attorney Marilyn Mosby went one step further and announced her office will no longer prosecute any marijuana possession cases — regardless of the quantity of marijuana or the possessor’s criminal record — and will divert all individuals charged with first-time felony distribution. She also announced her office will vacate nearly 5,000 past convictions dating to 2011.

This bold and groundbreaking decision has been met with a stubborn and unfortunate insistence by law enforcement leadership that arrests will continue. But with Baltimore suffering from a severe lack of trust in police due to decades of targeting communities of color, Ms. Mosby’s reforms are a critical step toward repairing law enforcement’s strained relationship with their community.

Baltimore, like many U.S. cities, is facing a pattern of disturbing conduct by some in law enforcement, including the over-policing of black neighborhoods and “zero tolerance” enforcement. The Department of Justice’s investigation of the Baltimore Police Department’s records from 2010-2015 found that BPD made 146 stops for every 100 residents in the predominantly black Western District and only 22.5 stops per 100 residents in the predominantly white Northern District. Despite similar rates of drug usage, BPD arrested black residents for drug possession five times more frequently than white residents. Those figures translate into neighborhoods where law enforcement is viewed as a hostile occupier, rather than a protector of public safety.

Decades of research make clear that public safety requires public trust. People are more likely to obey the law when they perceive law enforcement as fair and unbiased. And when trust in police is missing, victims and witnesses are less likely to report crimes. Indeed, we know that calls to 911 drop after high-profile instances of police brutality. We also know the “war on drugs” contributed to racially disparate enforcement. Criminalization of people who use drugs, especially those who use marijuana, has done little more than plunge our most vulnerable communities into intergenerational cycles of poverty, trauma, incarceration and disenfranchisement. Conversely, the growing trend to decriminalize or legalize marijuana strengthens public safety, decreases arrests, frees up law enforcement resources to focus on behavior that truly endangers communities and creates revenue for social good. These reforms are the essence of smart justice.

Forward-looking drug policy changes aren’t enough, though. We must also administer justice looking backward. When people are convicted of a crime, all too often the punishment never stops. Criminal records create barriers to education, housing and stable employment. Thus, while individuals may be physically released from cells, the confinement never ends.

State’s Attorney Mosby’s decision to vacate thousands of past marijuana convictions recognizes the immense barriers resulting from a criminal record. She joins prosecutors in San Francisco, Denver, Brooklyn, Seattle, and, most recently, Chicago committed to expunging thousands of past marijuana convictions.

Ms. Mosby’s announcement is part of a growing national movement to reconsider how the justice system addresses marijuana use, as well as drug policies more generally. Thirteen states, including Maryland, have removed the possibility of jail time for possessing small amounts of marijuana, and 10 other states and the District of Columbia have legalized marijuana. Yet even without legislative reforms, prosecutors around the nation — including in Houston, Philadelphia, St. Louis and Corpus Christi — are using their discretion to abandon strict marijuana enforcement and institute more humane policy responses that better reflect shifting community sentiment.

As our national conversation on the role of the justice system in regulating drug use evolves, it is important that policymakers do what is right, rather than what is easy. New policies should go beyond simply not prosecuting first-time offenders and should avoid using low quantity thresholds that continue to criminalize people for marijuana use. They should avoid probation and parole conditions that perpetuate cycles of incarceration based on drug use and should include measures (such as those adopted in Baltimore) for expunging or vacating past convictions that have accumulated during decades of disparate enforcement. Finally, they should take a broader look at other substance use practices and laws that for too long have turned a public health concern into a criminal justice issue.

Miriam Aroni Krinsky (mkrinsky@fairandjustprosecution.org) spent 15 years as a federal prosecutor and is the executive director of Fair and Just Prosecution, a national network of elected prosecutors committed to new thinking and innovation. Brendan Cox (brendancox1988@gmail.com) is the former police chief of Albany, N.Y.