But then again, a non-trained and certified canon lawyer can only cite Canon Law, and not interpret it, and surely not enforce it. There may be truth to the basic statement that Penance is given as part of the Sacrament, according to CL, but like Constitutional Law, and other Law, CL is not always straight forward, and clearly black and white. That’s why there are canon lawyers.
What needs to be remembered about CL, is that it is not designed to just say what is right and what is wrong, to keep the clergy or laity in line, but rather it is to protect the faithful.
So, in this case, Canon 981 “MAY” (I say “may” again, to emphasize that as a non-canon lawyer, I can only speculate on the accepted Church interpretation of the law) reassure the person who received the sacrament without penance of the validity of the sacrament despite the possibility of an unlawful indiscretion of a priest.
In this way, we see the Code of Canon Law protecting one of the faithful, by declaring the validity of a possibly illicit (by incompletion in this case) sacrament, and the opinion of the Church that because of the honest contrition of the individual, they received absolution and the graces offered by the sacrament, and left reconciled with God, no longer in the state of mortal sin.
Peace and all Good!