Hacker News new | ask | show | jobs
by obstacle1 4859 days ago
> Of course you can be nice, but then code and product quality would end up affected.

Why? This attitude baffles me. You don't have to be a dick when reviewing someone's code, terrible or not.

> The person being reviewed knows it's not personal

It absolutely is personal if you make it personal, i.e. start personally insulting the author.

"How could you be so stupid to write this this way?"

"This is really idiotic code."

"Sorry, this dumb way of doing things is dumb, and I don't approve of dumb things in my project."

All of the above are personally insulting comments. You should not make comments like them if you value being civil.

There are plenty of ways to reject code without being a complete dick. For example:

"This is pretty neat, but I don't think it fits in here because _________"

"I really appreciate the commit, but _________ doesn't quite work with _______ idea."

"This is a great start. Could you change _____________ to meld better with ________?"

All non-confrontational ways to say "sorry, this isn't good enough" while also offering positive feedback.

2 comments

I found both types of examples you gave insulting.

Obviously being called dumb is insulting, but being treated like a baby is too.

What's so wrong with just saying

"This should be changed because ___"

"You should avoid doing something like this because __" ?

I always advise my staff to simply stick to the facts. Anything that can be disputed will be. This results in statements like:

"I'd like this changed because I believe it's a mistake to use globals in this context"

rather than

"You're/It's wrong to put a global here"

The difference is subtle, but important. It allows personal opinion to be used without the debate being personal.

That seems to be the direction I was looking for. It is subtle, but I see the difference. What I noticed in your example is two things:

1. The statement is framed as a personal viewpoint, rather than absolute truth/fact. 2. You not only state the problem, but also the intent or direction for a fix.

I'll try to see if I can adopt something along those lines. Thanks.

It's important to acknowledge personal differences while trying to see them as separate from the people themselves. It's when the two are confused that problems arise.

If you ignore personal differences, or don't understand that they're opinions (albeit based on experience) you will fail.

That's therapy training for you :)

I prefer a little explanation here.

"I've just had to track down bugs due to globals defined in this context when they don't need to be. If you use this approach it will save everyone a lot of time in the future."

Not confrontational, it's educational, and you're saying why it's wrong. Just saying "it's wrong" doesn't help if the original author didn't realize it was wrong at the time. If they did realize it was wrong and did it anyways, giving the full description just reminds them why they should go and do it the long way.

I prefer the ways you've verbalized it. Facts are good.

Just pointing out the opposite of being "not nice", and that it is still possible to be productive while being so.

not being nice != being a dick.

I never make rude and inappropriate comments or call people names. I do try to highlight mistakes or what I consider to be a wrong approach. Some of those well-articulated comments still some times get misinterpreted, and egos get involved in the discussion.

Wozniak is talking about not criticizing people, and in that respect, even a nicely put, well articulated comment is a form of criticism.