Everyone always wants to say worthy things about the qualities that make a good programmer. But I occasionally think that "a sense of humour" isn't given enough credit.
In programming, you're constantly making mistakes, and being told you're wrong (by code reviewers, bug reporters, and the computer itself). If you let that get you down, you'll quickly find another career.
When I realise I've made a mistake, my reaction is often to find it amusing – smile a bit, maybe laugh out loud, share it with a friend if it's funny enough.
I can't remember how I got that attitude in the first place. Perhaps just luck. But I sometimes think it's the main reason I stuck with what would otherwise be a frustrating profession!
@simontatham you may also have a history of jobs where you could feel safe generally. The first thing we all need is to normalize mistakes and feel like they're ok and part of learning. Laughing at what we've done can't happen when we're afraid for our jobs. Glad you're in a tolerably healthy place, however you got there tho!
@ren totally agree – a workplace that puts you under constant pressure to never make a mistake is utterly toxic. _Especially_ if you feel under that pressure from day 1 when you're still learning your way around, because it's even more obvious that people will make mistakes while learning than that they'll carry on making mistakes once they're up to speed (though both are true).
Not only that, but a workplace of that kind isn't even serving its _own_ interests, because if it's trying to incentivise employees to never make a mistake, what it's really doing is incentivising them to never _look_ as if they make a mistake. So the mistakes get covered up and the company never finds out about all the problems.