Maybe my post wasn’t clear regarding the difference between discernment and judgement.
Discernment - the ability to recognize sin, i.e. “warning of dangers ahead”.
Judgement - the condemnation of the sinner, i.e. “casting of stones”.
Catholic Dictionary
DISCERNMENT OF SPIRITS
Definition The ability to distinguish whether a given idea or impulse in the soul comes from the good spirit or from the evil spirit. It may be an act of the virtue of prudence, or a special gift of supernatural grace, or both. In persons who are seriously intent on dong God’s will, the good spirit is recognized by the peace of mind and readiness for sacrifice that a given thought or desire produces in the soul. The evil spirit produces disturbance of mind and a tendency to self-indulgence. An opposite effect is produced by both spirits toward sinners. (Etym. Latin discernere, to distinguish between, determine, resolve, decide.)
Catholic Dictionary
JUDGMENT
Definition In general, an act of the mind affirming or denying something. Philosophically, judgment is the mental act of combining two ideas in affirming their agreement, e.g., God is good, or separating them in denying their agreement, e.g., God is not evil. In ethics, judgment is a right decision about what is just or proper or prudent. It is also the decision of a superior in a natural society (such as the State) or a supernatural society (such as the Church), prescribing what should be done or administering justice.