I wrote a paper with some coauthors who are more senior than me (I am a grad student) and it got published although not in a top journal. I thought I understood it and followed the proof line by line but I have been asked to give a talk about it and now I realize that the paper is not very good. We claimed to improve a result of some other people and actually one of our main theorems that we spend lots of space proving is a trivial consequence of theirs just worded differently so I'm worried that giving a talk about this paper will make everyone in the audience just think I'm/we're stupid for not noticing this. I was specifically invited by someone interested in the topic so I can't even talk about anything else. What should I do? Pretending I don't know it's bad gives me more chance to get away with it but seems dishonest. Owning up to the problem sounds like career suicide. And I don't have a good reason to cancel the talk but I'm thinking of saying I'm sick and I can't make it because I really wish this paper doesn't exist.
Buffy's answer is quite good, but it's important to add:
Check with your coauthors that you're actually right in your assessment.
I've definitely had the experience of mistakenly thinking something I've proved is a trivial consequence of something else, when in actuality there was a slightly subtle reason the "something else" didn't actually apply. (And, yes, I've also had the experience of realizing correctly that something I did was a trivial consequence of existing work - or indeed simply trivial on its own.)
Another important aspect of the above is:
Don't surprise your coauthors with this observation.
Think of it form their point of view: how would you feel if one of your coauthors were to give a talk on your paper, and midway through unexpectedly announced that they'd discovered that one of your results was trivial?
I'm pretty sure you aren't alone here. People find surprising things all the time. Be thankful that you are the one who found it.
This may sound risky, but I don't believe it is. Give a technical description of the problem as you normally would and then give an historical tour through what you originally thought and what you now think and why.
Rather than being career suicide, you will, IMO, be thought refreshingly honest and open to the truth wherever it leads. If you "get away with it now" but don't later, things will be much worse. Much much worse is if a student in your talk raises his/her hand with ... well, you know.
Out with it my friend. Just take a deep breath and say it all. You can even say that you feel a bit silly now that you've gotten a deeper understanding. Noting wrong about a deep understanding, of course, even if it eludes you early.
And, of course, your more senior colleagues and the reviewers, if any, also missed the point. You are a hero, not a bum. The math is what it is.
Another option, of course, is to say that you have found an issue along with the consequence but then talk about another topic. But I think that would disappoint people. Seeing the flaw can, itself, be enlightening.
In my discipline, part of the purpose in giving talks is to thrash-out ideas which might not be particularly brilliant, in order to get feedback from your audience, so that you can build on the ideas or find better ideas. Academia is supposed to be collegial, which means that we should give and receive robust yet constructive criticism on work-in-progress (and I think you should treat your paper as work-in-progress with potential for future development, even though it has already been published) in order to advance scholarship now and in the future. In other words, a talk need not be a perfect and earth-shattering result.