According to the Catechism the “Sunday Eucharist is the foundation and confirmation of all Christian practice. For this reason, the faithful are obliged to participate in the Eucharist on days of obligation, unless excused
for a serious reason (for example, illness, the care of infants) or dispensed by their own pastor. Those who deliberately fail in this obligation commit a grave sin (2181).
Those who ”obstinately persist in manifest
grave sin are not to be admitted to Communion” (Canon 915).
St. Paul urges us to examine ourselves before receiving communion: "Whoever, therefore, eats the bread or drinks the cup of the Lord in an unworthy manner
will be guilty of profaning the body and blood of the Lord. Let a man examine himself, and so eat of the bread and drink of the cup. For anyone who eats and drinks without discerning the body eats and drinks judgment upon himself." Anyone
conscious of a grave sin must receive the sacrament of reconciliation before coming to Communion (Catechism, 1385).