I learned a beautiful thing in R' Yitzchak Ginsburg's "Living in Divine Space":
He says that the Baal Shem Tov taught us that we mustn't let humility prevent us from serving Hashem. However unworthy we may feel we are, if we approach serving Hashem with such feelings, we'll lack enthusiasm and zest - and these are things we need when serving Hashem. And on the other side - once we've achieved something - we learned, davened, whatever, then we need to have humility that it was really all a gift from Hashem.
He connects this to the words "Sh'giah" (to make a mistake) and 'Va'Yigash" (to come close - as used in parshas Vayigash). The root of both words are the two letters Shin and Gimmle. In the word for mistake, sh'giah, the shin comes before the gimmel. In the word 'to come close', hagashah, the gimmel precedes the shin.
He says that the gimmel stands for gaavah, arrogance, and the shin for shiflut, humility. The way to come close to Hashem is to first have arrogance - to approach Him and serve Him despite our faults, but then afterwards to have humility, to know that whatever we achieved is all a gift from Him.
But if we put the shiflut first, so that we don't serve Him with enthusiasm and zest, and then put the gaavah afterwards, taking credit for whatever we did achieve, then we're on a mistaken path.
With a sin, it's the other way around. Before the sin, we need shiflut, the knowledge that only Hashem can help us. But if a person fell already, he needs to push aside depression and guilt and 'be haughty' to serve Hashem with renewed diligence, despite his faults.