Every time I make progress on any side project, self-doubt and fear creep in. It demotivates me from working. Usually it starts when I hit a snag in development, either a bug I can't figure out, not being able to decide how to design something, a major refactor is needed, or the realization I have to learn a lot before proceeding. I know logically everyone has to go through this and I need to push through, but my mind focuses on failure so much that it cripples my ability to try and complete anything. This is compounded when I see someone else's success on a similar project, I get even more demotivated and start to believe in my own inferiority.
This same fear makes me not want to practice leetcode, and thus stops me from trying to pursue another job. Does anyone have any coping tips? I just want to improve my skills and enjoy coding again.
"Fear is usually based in an abstract concern. Try to make it more concrete. What are you actually afraid of? For example, you're probably not actually afraid of losing your job, but losing your paycheck. But you're not actually afraid of losing your paycheck, you're afraid of not paying your bills. But you're not actually afraid of not paying your bills, you're afraid of being evicted. But you're not actually afraid of being evicted, you're afraid of where you'll live afterwards. And then you realize you haven't actually thought about this situation, so it's just an abstract worry.
So your entire fear base is based on this abstract fear of "What will I do? I'll be screwed." If you dig into it more, you'll find concrete solutions. You might realize you have lots of savings so getting evicted due to not paying rent is really unlikely. And if you do get evicted, you can just go crash at a friend's place while you figure out your next steps. And worst case if no next steps happen, you can live with your parents. Etc etc.
I often find when doing this exercise is that what I'm actually afraid of is very unlikely to happen. It's the worst version of the worst scenario. And even if it does happen, it's actually not that bad and I can handle the situation just fine."
To find it again, head to your profile -> Favorite comments
If you forget to 'favorite' a comment and vaguely remember it, sometimes a google search with site:news.ycombinator.com will do the trick.
Another way is you can use the HN searchbar (at the bottom of the page), and when it loads results, switch from searching stories to searching comments. E.g. https://hn.algolia.com/?dateRange=all&page=0&prefix=false&qu...
Games can be tough at first as there's lots of things going on at once, and you could be trying to write a novel before being fluent in your ABCs.
Get used to finishing what you meant to do. Before starting a project, plan to finish it. If you can't finish, rescope it. You get experience for each project you finish, so the optimization is to finish more.
Decide how much time you have. Then set a schedule, one that you can commit to.
You can have a roadmap, set out to deliver things per release. Or just say you're done with it and do something else.
With sufficient experience, you might decide to make higher quality projects in full. Or you can keep incrementally increasing the ones you have.
I'd be surprised if there's anyone here who hasn't also experienced this.
In most non-trivial projects, there'll be be some unanticipated knowledge that has to be learned and applied along the way. Sometimes it can take longer than expected. From my experiences I'd guess at least 30% of my dev time gets spent on weird, unanticipated aspects (swatting bugs, or dealing with something I thought would be trivial, or often some third-party thing I can't control). Whether that's my lack of foresight or the norm is another question.
But I think it's normal and will diminish over time. As long as you're making things and learning, you'll keep encountering bugs/topics/problems you have to solve. You'll get used to it and recognise it's only temporary.
Comparison is the thief of joy. Like for every time you compare and get jealous, you could have leveled up, for YOU personally. The only person you need to be in competition with is YOU.