Live data from Hacker News

Don’t teach during code reviews

michaelagreiler.com

1–10 of 304 posts

Re: Don’t teach during code reviews

#2
> I’m not sure if I understand the whole idea but could you explain what this method does?

Maybe...It's going to depend on the culture. If you have a passive aggressive culture, something like this is a good fit. Otherwise, to me, you're adding friction.

Yes, it might be better to make the submitter think. But if you have to be anti-truth-seek to do it, that's a net loss.

Re: Don’t teach during code reviews

#3

> I’m not sure if I understand the whole idea but could you explain what this method does? Maybe...It's going to depend on the culture. If you have a passive aggressive culture, something like this is a good fit. Otherwise, to me, you're adding friction. Yes, it might be better to make the submitter think. But if you have to be anti-truth-seek to do it, that's a net loss.

This is not a question or discussion that should go in the code review record, IMO. If you do have this question during a code review then directly go have a chat with the person who wrote the code then go back to the review. It also quicker and easier.

Re: Don’t teach during code reviews

#5
Great article, I like the thought here. I've fallen for this myself, trying to "teach by asking questions", but in reality just come off as patronizing or disrespectful to your counterparty. That kind of thing is a lot more suited for a discussion where it's legitimately important that someone come to the conclusion for themselves (eg, a political argument). A code review is different, both parties already have an implicit obligation to be receptive and open to feedback. You can be direct, and talk somewhere else about the "grand lesson" if you want.

Re: Don’t teach during code reviews

#6
I disagree with the title but found myself agreeing with many points in the article.

“Don’t be condescending” seems like generally applicable advice. But IMO, sometimes you just know something the code submitter doesn’t (or vise versa) and discussing that can be useful. And i think that’s pretty much teaching!

Re: Don’t teach during code reviews

#8
Isn’t that more “don’t give vague feedback” or even “don’t misdirect the reviewee”?

“I’m not sure if I understand the whole idea but could you explain what this method does?” misdirects by suggesting the reviewer thinks they need education, rather than that the reviewer thinks the code can be clearer.

Re: Don’t teach during code reviews

#9

> I’m not sure if I understand the whole idea but could you explain what this method does? Maybe...It's going to depend on the culture. If you have a passive aggressive culture, something like this is a good fit. Otherwise, to me, you're adding friction. Yes, it might be better to make the submitter think. But if you have to be anti-truth-seek to do it, that's a net loss.

> If you have a passive aggressive culture, something like this is a good fit.

That would perpetuate the passive aggressive culture.

Post reply on HN