The Grace of our Lord Jesus Christ be with you all.
Like almost all of mass it is a Bible verse, (2 Thessalonians 3:18), one every Catholic knows.
Now to the hard part.
St. Paul in this letter does give a clear and harsh instruction:
We instruct you, brothers and sisters, in the name of our Lord Jesus Christ, to shun any brother who walks in a disorderly way and not according to the tradition they received from us.
Some Christians take shunning very literally. Once a person is shunned, they are cut off from the community.
For us, the most severe penalty we have, excommunication does not separate the person from the community. As the catechism says, it “ impedes the reception of the sacraments and the exercise of certain ecclesiastical acts.” The excommunicated person is still Catholic. They are still a member of the Church. They are still a member of their parish. They still have, not only the right, but obligation to attend mass. They are still your brother or sister in Christ. They cannot receive sacraments and cannot exercise certain other offices.
In the Catholic Church, we follow the instruction of Mt. 18 and so the penalty is only imposed after every other method of bringing about conversion is tried. It cannot be imposed or declared by your local priest but only by the bishop as a last resort and the goal is always conversion, bringing back the lost sheep.
This verse from St. Paul is a perfect example of why we must read each verse in the context of the whole Bible, in particular the gospels. Taken by itself, it would seem to encourage the individual Christian to judge the behavior of another and penalize the person they don’t think is living the Christian life. Taken in context we know that we as individuals have no such right.