A change to how the Canada Revenue Agency interprets a section of the tax law spiralled into a public relations nightmare this week that ended with a ministerial tongue-lashing for public servants and a tweet from the prime minister himself promising retail workers he wouldn't tax their employee discounts.

How did a bureaucratic change made a year ago get to that point?

At issue is a "folio" updated by the tax collector last fall and posted on the CRA website. It was a belated response to a 2011 Federal Court ruling that demanded clarity on how the Income Tax Act is applied to discounts offered to employees, which are (with few exceptions) deemed as taxable income under the act.

With the folio, the CRA advised retail employers that when an employee receives a discount on merchandise, the value of the discount should be included in the employee's income at tax time.

The whole exercise was about "clarifying" the law, Liberal MP Marco Mendicino said Tuesday during an appearance on CBC's Power & Politics. "If you've got an employee discount that is not available to the public at any point in time, then it will be categorized as a taxable benefit," he said.

The next day two cabinet ministers were sent out to nix the move and condemn the CRA.

A spokesperson for Revenue Minister Diane Lebouthillier said she was "deeply disappointed" in the bureaucrats who hatched the plan and released it without the minister's approval. The agency was ordered to take the new interpretation off the website and begin industry consultations to find a more palatable response to the court decision.

"This document was not approved by the minister and we are deeply disappointed that the agency posted something that has been misinterpreted like this," the spokesperson said.

About-face

But on Tuesday evening, one day before that public climbdown, it was Lebouthillier's office that was briefing reporters on how, exactly, the measure would be applied in the next tax year.

A spokesperson told CBC News the changes wouldn't affect fast food or restaurant workers, for one, and that the onus would be on employers to track discounts applied on employee purchases and report that as income on employees' T4s at tax time.

"There have been no changes to the laws governing taxable benefits to retail employees. We are not targeting individuals working in retail," the minister said in a statement.

The next day, she was calling on CRA to strip the policy from its website.

'I can't help but shake my head'

Initially, the change to the CRA advice went largely unnoticed — by the media and opposition parties alike — except for the Retail Council of Canada, which started raising red flags with the agency in October 2016 and later with the minister's office over the summer. The minister's office did not respond to the council's inquiries, an oversight later attributed to a staffer's extended absence.

The council's criticism resurfaced last month, when Karl Littler, vice-president of public affairs with the group, told the House of Commons finance committee that the CRA's proposal would be an "administrative nightmare" for retailers (tracking all employees' sales, and whether those discounted prices were offered to the public, among other demands). When asked if the government had responded to his concerns, he said the group received nothing but "a pro forma response."

Liberal MP Wayne Easter, chair of the finance committee, said he thought the folio was largely nonsensical. "I can't help but shake my head at this one to be honest with you," he told Littler.

Wayne Easter, the Liberal chair of the finance committee, said he couldn't understand the reasoning behind the CRA's proposal to tax merchandise purchased with an employee discount. (Steve Bruce/CBC)

Conservative MP Dan Albas asked only if Littler had received a response from the minister's office, but mostly directed his questions to the state of the retail industry.

MPs - Marco Mendicino, Pierre Poilievre, and Pierre-Luc Dusseault discuss 8:47

Then, on Thanksgiving Monday, the Globe and Mail reported on the change, other media picked it up and the government found itself in the midst of another tax controversy.

The Conservatives seized on the issue, blasting the government for attacking low-income workers. "It's perfectly consistent with Justin Trudeau's uncontrollable addiction to spending. He's running out of other people's money and now he's asking CRA to find him more," said Pierre Poilievre, the Conservative finance critic.

Concerns about ministerial interference

Social media lit up with complaints about the proposals, and then damage control was set in motion — prompting the strong statement from the minister's office and a pinch-hitting performance by Treasury Board President Scott Brison on the evening political TV shows.

'This does not reflect our plan as a government,' says Treasury Board President Scott Brison. 10:04

To drive home the point, Prime Minister Justin Trudeau, following a day of meetings about NAFTA on Capitol Hill and at the White House, used his Twitter account to reiterate the government would be instructing CRA to back away from its proposed interpretation.

Let me be blunt: we are not going to tax anyone's employee discounts. Minister <a href="https://twitter.com/DiLebouthillier?ref_src=twsrc%5Etfw">@DiLebouthillier</a> has asked the CRA to fix this. —@JustinTrudeau

The political involvement prompted one tax attorney to write CBC News with concerns about ministerial interference.

"[I] find it astonishing when elected officials tell CRA how to apply existing laws. When it happens, bureaucrats are no longer free from any political interference," Valentin Erikson, an Ottawa-based tax lawyer, said in an email.

"Politics is politics, but this is akin to a justice minister telling judges what conclusion they should come to before rendering their decision.

"If you don't like existing law — tell [the] finance minister to change it!"