R. v. Fabbro, 2021 ONCA 494, July 5, 2021, at paragraph 25:
For mental health to be considered a mitigating factor in sentencing, the offender must show a causal link between their illness and their criminal conduct. That is, the illness must be an underlying reason for the conduct. And, there must be evidence that a lengthy sentence would have a serious negative effect on the offender such that it should be reduced on compassionate grounds. See R. v. Megill, 2021 ONCA 253, at para. 171; R. v. Hart, 2015 ONCA 480, at para. 6; and R. v. Pioriello, 2012 ONCA 63, 288 O.A.C. 198, at paras. 11-12. In Hart, on a Crown appeal, this court upheld the conditional sentence imposed by the trial judge where the mitigating factors included the inference that the appellant’s mental health played a causal role in the commission of the offence.