Yes. This is the Doctrine of the Catholic Church. Nobody can know for sure if he is in a state of Grace (ie, has not committed an unconfessed mortal sin). Thus, it stands to reason that we can never know for sure if any sin we commit is mortal in nature (if we could know that, we could know for sure that we are not in a state of Grace - which we cannot ever know).
I think I see where you are trying to go. Part of the “knowledge” aspect requires an understanding of the grave nature of the act. And if we can never know for sure the gravity of the act, we can never have full and complete knowledge, and thus cannot ever commit mortal sin.
And that’s a good point. I may need to reconsider my opinion that we cannot know the gravity of the act. As far as I am aware, I am the only Catholic to ever form such an opinion (I seriously doubt that I am, but it is not something I have never seen before).
Of course we can know the gravity of an act. In some instances - eg abortion - we know it because the church has said explicitly that it is grave matter in any circumstances.
In other instances - such as lying - the church has said that the gravity of a lie depends on various factors, such as the nature of the truth we are deforming, the harm we do to others by our lie and so on.
In such circumstances we can still know the gravity of our sins. We can use the guidance the Church offers plus our informed conscience to make a determination that in the particular circumstances in which we lied, our lie was grave matter (eg perjuring oneself in court, on oath, would rarely if ever not be grave matter, and I think a person can use reason and informed conscience to decide which). Or that in the particular circumstances (eg telling your wife ‘no, those jeans do not make your bum look look big’ when they do) it was not grave matter.
Think of the relationship analogy. There are some misdeeds that would be a ‘deal breaker’ for pretty much any couple - infidelity, for example. It’s very easy to objectively say ‘no, you shouldn’t cheat on your spouse’.
There are others that are a ‘deal breaker’ only for some people. Every couple will have different standards as far as household chores, for example. So every couple will know that they should at least not have so much rubbish about the house that vermin is attracted or health and safety compromised, but beyond that there is no ‘one size fits all’ for each couple.
Within that couple, there will often be one partner to whom it matters more than to the other. Or times at which it matters more - eg they may be more tolerant of mess if they have a newborn baby or something.
Nonetheless, a spouse CAN oftentimes make a good guess as to what their partner’s expectations are in regard to household chores, without being explicitly told. Or decide to clean house regardless of what their partner thinks because they personally are uncomfortable with the level of mess and it is a big issue for them.
That’s how it works in our relationship with God as well. Sin is a rupture in the relationship, mortal sin is a serious one. A relationship can be ruptured equally from our side (ie by us doing things that we are not comfortable with, that we are fairly sure are grave matter) as from God’s (ie doing things that indisputably and whichever way you slice it are grave matter).