ספר המדות Haughtiness · כט
Sefer HaMiddot 491
כט. כְּשֶׁנִּזְדַּמֵּן לְךָ עֲבֵרָה בְּלִי דַּעַת – בְּוַדַּאי יֵשׁ לְךָ גַּאֲוָה, וּבָזֶה מַרְאִין לְךָ, שֶׁעֲדַיִן אֵין אַתָּה צַדִּיק.
29. When you happen upon a transgression without awareness, it is certain that you have arrogance, and through this (accidental sin, Heaven) is showing you that you are not yet a tzaddik (t.n. See also #19).