There is only one cure for self righteousness.
A.) God's Grace
The cure for self-righteousness is humiliation.
Philippians 3:21 He will change the body of our humiliation to be conformed
to the body of his glory, according to the working by which he is able even
to subject all things to himself.
He gives grace to the humbled.
James 4:
5 Or do you think that the Scripture says in vain,
The Spirit who dwells in us yearns jealously?
6 But He gives more grace. Therefore He says:
God resists the proud,
But gives grace to the humble.
Conformed to His image.
Acts 8:
32 The place in the Scripture which he read was this:
He was led as a sheep to the slaughter;
And as a lamb before its shearer
is silent,
So He opened not His mouth.
33 In His humiliation His justice was taken away,
And who will declare His generation?
For His life is taken from the earth.
When the Holy Spirit leads us to a place where the carnal nature
is humiliated, to crucify the flesh, we are the better for it.
He gives more Grace. Humbled to receive.