I would say looking at the positive side and honestly praising someone is a good deed. On the other hand, completely lying with the intention to mislead a person is a sin. Also lying to make a person feel good is not a good thing, as you may mislead them in a wrong direction.
No matter how bad someone is, there is a positive side of that person and there is an honest way of praising and encouraging them. Lying in all cases is bad.
For example a very bad person ask you what you think about him. You can always praise that person for trying to get feedback to understand where he stands. First praise him for caring about your opinion. State all good things that you know of that person and afterwards point toward the areas he can improve and how he can improve.