The Bible clearly states that fearing God and hating evil are inseparable.
The fear of the Lord is hatred of evil. Pride and arrogance and the way of evil and perverted speech I hate. Proverbs 8:13 ESV
However, Jesus responded to some sinners with great compassion and others with great rebuke. It was not the degree of sin that made the difference, but the penitence of the sinner.
In general, those who admitted their sin and their need for salvation received grace and mercy and compassion. Those who were self-righteous, however, received rebuke.
Nicodemus was a Pharisee, but Jesus dined with him, because his heart was receptive to Jesus. We know this because Nicodemus is mentioned not only in John 3, but after the crucifixion, when he, with Joseph of Arimithea, take Jesus' body to the tomb.
For us, we should indeed imitate Jesus and hate sin and condemn it in our own lives wherever we see it. We should also condemn it in others, not verbally, perhaps, but certainly in our own hearts.
For unbelievers, we should expect them to sin. Our posture towards them should be one of love that shares the gospel of Christ with them. God will deal with their sins later.
For other believers, there is church discipline that we are to exert, but that is in communion with others.