I rarely give up but then it depends on at what point an idea you are trying out escalates to a full on emotional commitment to that idea.
I think timing plays a significant part. I'm working on something at the moment that I first had the idea for 4 years ago. The bits I need and the skills have only just come together. I won't pretend that my idea has any great significance but it is one of those nagging thoughts that won't go away.
The? people who critique the idea have a big influence. I have colleagues whose advice or lack of buy in would make or break the idea. Then there are the people who Dunning & Kruger would use as examples to illustrate the cognitive bias the pair studied. No-one could possibly be as good as such people think they are.