Live data from Hacker News

I ruin developers’ lives with my code reviews and I'm sorry

habr.com

111–120 of 164 posts

Re: I ruin developers’ lives with my code reviews and I'm sorry

#111
As long as the code does what it is supposed to do with acceptable performance then I don't comment and approve the PR.

Because unlike people that think there are right ways I know that it's all religious arguments. Last I checked there are 0 credible reproduced scientific studies about what is the correct way to program. Or even a better way. So as far as I'm concerned it is all opinion based and sure I also have my opinions but, consistency, rule of least power, DRY, agile, OOP, single responsibility principle etc etc are all religious notions.

There are only 2 things that matter: does it work? does it work fast enough?

And normally the arguments boil down to: "Oh but it is not changeable!" - maybe you should make something new "I can't read it!" - I also can't read Chinese "I don't like it" - well not everyone likes chocolate

Re: I ruin developers’ lives with my code reviews and I'm sorry

#112

an or condition in a constant; yeah you'll be the judge...

Are you implying there's something wrong with that?

it's a "constant" so it's value cannot be altered during execution of the application.

basically starting a rant about being a tightass about code review with a bad piece of code

Re: I ruin developers’ lives with my code reviews and I'm sorry

#113
I do a lot of code reviewing, and I still have to use the backspace key sometimes when I find myself oversuggesting. I have found code reviews (when done well) to be a fantastic teaching tool. I also think that we get some great value out of code review by less experienced folks too. Those developers without decades of knowledge sediment are more willing to say, "I'm sure this block is awesome but I have read it 10 times and I still don't understand what it does." That turns into one of two things: an opportunity to educate the reviewer, or a sign to the author that the code is too complex (i.e. less peer-maintainable).

Re: I ruin developers’ lives with my code reviews and I'm sorry

#114

As long as the code does what it is supposed to do with acceptable performance then I don't comment and approve the PR. Because unlike people that think there are right ways I know that it's all religious arguments. Last I checked there are 0 credible reproduced scientific studies about what is the correct way to program. Or even a better way. So as far as I'm concerned it is all opinion based and sure I also have my…

I agree with you, a code review isn't meant to get the best code ever, mostly because as you said, there's no universal correct way, but it's meant to make sure the code change is doing what it's means to be doing.

What is not clear in your comment though is that that means looking at the code and making sure there's no mistake too in it too.

It may seems like it's working as expected, but maybe you'll find an edge case that was missed by the original developer.

It's possible too that the solution of the original developer was clear to him, or that it's clear knowing the context of the ticket, but once in the wild, that code may become incomprehensible (which later on can bring more error because someone misunderstood why that line was there and changed it incorrectly for example). That can be easily fixed by adding a tiny comment there.

Sure doing what it's supposed to do in an acceptable performance is great, but I think there's a bit more into a code review and ignoring theses can be quite problematic.

> "I can't read it!" - I also can't read Chinese

Doesn't this show there's an issue though in the long term? If you are the only one that can read Chinese in the company, maybe it would be a better idea to consider using English?

Re: I ruin developers’ lives with my code reviews and I'm sorry

#115
For this reason at my company we often do the code review of a junior developer's first pull request in person and in private. I think it's worked decently well to ensure that comments can be the start of a conversation and not a reprimand, and to help the junior to understand that the comments are not meant to be a personal criticism.

Re: I ruin developers’ lives with my code reviews and I'm sorry

#116
Well, all I can say is I'm glad my team of developers is not like this. Though there was one code review from my senior engineer going increasingly heavy on asking for documentation examples on a specific function. I felt like he was angry with me but maybe he just had a strong feeling those examples were important... Actually I will never know so time to forget it :)

Re: I ruin developers’ lives with my code reviews and I'm sorry

#117

Earlier quoted context omitted.

You do want to express yourself, don't you? (Sarcasm, Office Space reference, I'm with you on the stickers.)

Agreed. I'd much rather not advertise for anyone/company, and especially not throwing sticky residue all over my expensive laptop.

In addition to a shared aversion to voluntarily turning my possessions into billboards, I'd like to add there's real value in keeping computing devices generic looking.

By plastering your laptop with a completely unique combination and placement of stickers one can discover in videos or photographs online from conferences or talks for example, you make it a whole lot easier to pick out your unattended machine from a set, a hotel room, or luggage.

This can easily be leveraged by assisting targeted theft, destruction, or sophisticated physical access attacks.

Re: I ruin developers’ lives with my code reviews and I'm sorry

#118

As long as the code does what it is supposed to do with acceptable performance then I don't comment and approve the PR. Because unlike people that think there are right ways I know that it's all religious arguments. Last I checked there are 0 credible reproduced scientific studies about what is the correct way to program. Or even a better way. So as far as I'm concerned it is all opinion based and sure I also have my…

In practice there are things that are not religious arguments nor problems of technical correctness.

For example, in a recent code review I found a function where an argument was being passed in but not used, and a constant of the same type with a similar name was used in the body of the function. That obviously happened because the author got halfway through refactoring their code and didn't realise, and we were both happy to fix it.

Re: I ruin developers’ lives with my code reviews and I'm sorry

#119

"If a guy brings me his code, and it has mistakes, it brings insane pleasure from how smart I feel ... And if you tell me that you haven’t had this feeling ever, then you’re lying." I can tell you I haven't had this feeling ever, but not for reasons I'm proud of. I hate doing code reviews. I have hated doing every one. I have disliked having to type every comment I have made on a code review. Each time I hope that ev…

> And I won't comment unless I am convinced it is important.

I tend to lean this way as well. Im of the mindset that most things that are "caught" in a code review don't add any real value. Or maybe I just have bad coding standards.

Re: I ruin developers’ lives with my code reviews and I'm sorry

#120

This is incredibly honest. Maybe it's just me, but it 100% resonates with me. I find myself doing the exact same thing: as soon as I feel myself mounting up on my high-horse I have to talk myself down from being an asshat. I've gotten better at it because I'm now responsible for people's careers, and my pettiness is no reason to make someone's life suck because they are still learning -OR- because they think differen…

A practice I've become interested in but don't have an opportunity to engage with(doing the solo ISV thing) is "mob programming", since it confronts a few axes of the toxic-developer problem:

* There is some built-in diversity of skillsets, if not demographics, by pushing team communication into a continuous meeting format where non-developers are given space.

* It forces some vulnerability into the mix, which gets you into a less inhibited state: "I don't know, but" is way more common if you literally can't run off and prepare some slick answer to every question or hide behind your ownership of the solution space.

* The I/O bottleneck of having a whole crowd at one screen moves the emphasis away from the lines of code, and towards the broader parts of problem solving and getting feedback. Everyone that's experienced always says that it's not how fast you type that matters.

* Feedback becomes less punishing. Everyone gets a chance to drive, make some minor errors, and immediately correct them, which keeps everyone on the same level and encourages a healthy attitude to learning, vs the anxious/punishing "all-seeing-eye judgment" nature of batch code reviews.

But mostly, I like the idea of a hypothetical mind-melded "superdeveloper" emerging from a mob - a coder that pumps out extremely high quality code solving exactly the right problems in a single iteration, without breaking a sweat. I do think I've seen it in bursts in the past, just not in a systematic fashion. My experiences with pair programming definitely suggest that it adds intensity to problem solving that isn't there alone, and it makes me suspect that we may just straight-up be "doing software wrong" by focusing on quantities of code edits and not the overall communication flows.

Post reply on HN