The assembly of disciples (aka church) is not a fellowship of perfect people. We are a fellowship of the forgiven who, by God’s grace, are pursuing a life of holiness and obedience to our Master. We dare not fall into spiritual pride by thinking that we are better than a member who has fallen into a pattern of missing God’s goal. Paul says that our response to that in a disciple should be to mourn.
But if we do not deal with those who refuse to repent of missing God’s goal as the Master commands, His life will soon blend in with the world and the salt will lose its savor. The Master warns that He will come and remove our lampstand. So we must practice biblical church discipline toward professing the disciples who persist in missing God’s goal.
God’s holiness is a dominant theme in the Bible. It means that He is totally apart from and opposed to all sin. In the Old Testament, God told His people Israel
“You shall be holy, for I the Master your God am holy.” | Leviticus 19:2
The New Testament repeats that command
But as the one who called you is holy, you also are to be holy in all your conduct; for it is written, Be holy, because I am holy. (1 Pet. 1:15-16).
Peter refers to the church as a holy priesthood and a holy nation
But you are a chosen race, a royal priesthood, a holy nation, a people for his possession, so that you may proclaim the praises of the one who called you out of darkness into his marvelous light. (1 Pet. 2:5, 9).
Because of this, when God’s people miss His goal, He will disassociate Himself from them and take them through severe discipline if they do not repent and deal with the problem in their midst. You see this often in the Old Testament (e.g., the story of Achan, Joshua 7), and also in the New Testament.
In the messages to the churches in Revelation 2 & 3, the Master repeatedly warns that if they do not deal with their shortcomings, He will set Himself against the church and even remove that church’s lampstand. God would rather have no testimony in a city than to have His name mingled with corruption.
Matthew 18:15-17 New American Standard Bible
If your brother sins, go and show him his fault in private; if he listens to you, you have won your brother. But if he does not listen to you, take one or two more with you, so that by the mouth of two or three witnesses every fact may be confirmed. If he refuses to listen to them, tell it to the church; and if he refuses to listen even to the church, let him be to you as a Gentile and a tax collector.
1 Corinthians 5 New American Standard Bible
This seems pretty clear.
It is actually reported that there is immorality among you, and immorality of such a kind as does not exist even among the Gentiles, that someone has his father’s wife. You have become arrogant and have not mourned instead, so that the one who had done this deed would be removed from your midst.
For I, on my part, though absent in body but present in spirit, have already judged him who has so committed this, as though I were present. In the name of our Master Jesus, when you are assembled, and I with you in spirit, with the power of our Master Jesus, I have decided to deliver such a one to Satan for the destruction of his flesh, so that his spirit may be saved in the day of the Master Jesus.
Your boasting is not good. Do you not know that a little leaven leavens the whole lump of dough? Clean out the old leaven so that you may be a new lump, just as you are in fact unleavened. For the Messiah our Passover also has been sacrificed. Therefore let us celebrate the feast, not with old leaven, nor with the leaven of malice and wickedness, but with the unleavened bread of sincerity and truth.
I wrote you in my letter not to associate with immoral people; I did not at all mean with the immoral people of this world, or with the covetous and swindlers, or with idolaters, for then you would have to go out of the world. But actually, I wrote to you not to associate with any so-called brother if he is an immoral person, or covetous, or an idolater, or a reviler, or a drunkard, or a swindler—not even to eat with such a one. For what have I to do with judging outsiders? Do you not judge those who are within the church? But those who are outside, God judges. Remove the wicked man from among yourselves.
The church must practice biblical church discipline toward professing disciples who persist in known sin.