The federal government set out to end the harsh use of solitary confinement in Canadian prisons.

But, Bill C-83, which passed just before the House of Commons rose last week, doesn’t do that.

It gives solitary a new name, “structured intervention units,” and drops it to 20 hours a day, conveniently falling just outside the United Nations technical definition.

But there’s no real limit to how many days someone might remain in solitary and there’s insufficient independent oversight of these cases, especially for inmates with mental health issues.

The government seems to think it’s enough to say inmates should be released from segregation “at the earliest appropriate time.”

It’s really not.

In the case of Ashley Smith, whose tragic death inspired this legislation, prison officials in multiple institutions thought 1,000 days was appropriate. Indeed, the young woman’s time in solitary ended only when she choked herself to death with a strip of cloth.

The Trudeau government has taken major steps to reduce the use of solitary but it’s still overused by a prison system that argues it’s necessary to maintain security and protect inmates from each other and themselves.

A cap on its use is crucial because without one there’s no impetus for authorities to find real solutions for inmates, many of whom suffer from mental health issues that are only made worse in solitary.

The courts have already said as much. Most recently, Ontario’s top court ruled that solitary was “cruel and unusual treatment” because it “causes foreseeable and expected harm,” and limited its use to no more than 15 days.

That sensible ruling still hangs over the government’s head and Public Safety Minister Ralph Goodale seems to be just about the only one who thinks what the Liberals just passed will hold up in the face of that.

Everyone else sees a government that has set itself up for yet more court challenges by passing legislation that so obviously falls far short of what’s needed.