Frustration and sadness cause pity parties which lead to relapse. They sometimes begin with the declaration that "life isn't fair." When I used to say that, my sponsor would accurately point out, "And you are lucky it isn't because if you reaped what you sowed when you were using, you might not be alive." Bottom line: each day we need to recognize as early as possible when we are exercising selfish pity. It is less important why we are feeling sorry for ourselves, than substituting it with gratitude and perspective.
Nip the self pity in the bud by thinking of three things you are grateful for. Gratitude for breathing counts.