Live data from Hacker News

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

habr.com

171–180 of 199 posts

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

#171
post #115

Earlier quoted context omitted.

I'm curious to know if you or anyone else reading this has run into the opposite problem. Or maybe I'm just "that guy" although I am reasonably certain that I am not. As a rule, so far throughout my 5 year career as a full stack web developer, my coworkers have neither understood or cared about what clean code entails. I don't berate, I don't criticize, I've taken to mentioning it once and then doing my utmost to nev…

It’s possible there are things you are still learning, or context you are missing. You sound still early career enough that the years will likely mellow you out and teach you to better appreciate the ups and downs of building things fast. You know what’s worse than no abstractions? The wrong abstractions.

You are right on the value of building things fast.

However one thing I have learnt is more coupled the code is with no or poor incomplete abstractions less likely anyone is going to change it.

In the interest of shipping fast I would rather have some abstraction today rather than none, simply because nobody fixes spaghetti code which is already working.

Building new things start slowing down more and mode and you end up taking weeks for what should have been an afternoon's effort .

There are no right answers, however sometimes wrong abstractions can be marginally better than none.

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

#172
post #115
post #84

Earlier quoted context omitted.

I have worked with people like the author. They suck. They destroy entire teams and often times the feedback is 99% pedantic personal preferences because why would they do something useful like setup the linter and propose the silly things they always nit pick. These people don’t last long and I have gotten pretty good at screening out this personality in interviews after having it cause huge issues at two different…

I'm curious to know if you or anyone else reading this has run into the opposite problem. Or maybe I'm just "that guy" although I am reasonably certain that I am not. As a rule, so far throughout my 5 year career as a full stack web developer, my coworkers have neither understood or cared about what clean code entails. I don't berate, I don't criticize, I've taken to mentioning it once and then doing my utmost to nev…

Couple things about this, because there are levels. First, understand to be a successful engineer you need to be a bit pedantic, so start by forgiving yourself and take a deep breath.

Once you become competent enough to identify clean code, understand that your perception of clean code is colored by your own experience and current mental context. As you learn, you will undoubtedly be aghast at your own code that you wrote at any time before 6 months ago. After you've been at it for a couple decades you will come to the horrifying conclusion that your mental model is always incomplete, the human brain is weak, and it's hard enough to not get caught in the wrong local maxima without facing up to the immense challenge of choosing between global maxima in the incomprehensible problem space where software meets human needs in the hybrid meat/mental/cyberspace ecosystem where they exist and evolve over time.

The other implication is that no two engineers will ever see things the same way. It's not purely about technical strength—a weaker engineer might come up with a better solution given more time to think about it, or due to some other blind spot or skillset gap from the more senior engineer. Also, there are many issues of style and perspective where the important thing is consistency more so than some specific choice. In those cases there's a high risk of bike-shedding, and it leads to a fundamental truth of large scale software development which is that in practice you will never get everyone on the same page. Of course there are controls for this, but unless you have the budget and operational scope constraints of NASA (or perhaps medical device manufacturers) you can't actually enforce this without losing so much development velocity that your company is utterly uncompetitive in the market.

As you move up the seniority and scale ladder to larger projects and architectures, you will realize that you still only have 24 hours in a day, and it doesn't matter how smart or how right you are, the only tool in your built to increase your impact is a simple cliche: "pick your battles". There is absolutely no upside in nitpicking every line of code that could have a conceivable improvement. If you want respect from your colleagues, you need to get good at filtering what is important and what isn't, and only pointing out the most important issues, and doing it as early in the process as possible.

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

#173
post #84

Earlier quoted context omitted.

I have worked with people like the author. They suck. They destroy entire teams and often times the feedback is 99% pedantic personal preferences because why would they do something useful like setup the linter and propose the silly things they always nit pick. These people don’t last long and I have gotten pretty good at screening out this personality in interviews after having it cause huge issues at two different…

How do you typically screen for such personality characteristics? I'm curious since my current role involves interviewing a lot of engineers. I too have noticed similar traits in others in the past and I shamefully admit that I myself was pedantic about silly semantics and syntax in code reviews. Sometimes criticism of someone's code was warranted, and sometimes it wasn't and it was just me being picky (I like clean,…

Being picky is not the problem. Being picky and detail oriented is good quality to have as a developer.

We aren't artists, engineering is exacting field, more details you notice and remember better you can be.

The character trait you should look for how do they present that feedback, is it constructive , is it positive , the kind of language they use and how patient they are able to be.

One interview technique/tool that works for me is asking them to review some sample code mine or a junior devs.

It is easy to gauge how many kinds of issues, how many are actually important and how well they present feedback.

The other technique that worked for me is when I review their code in a interview, people who are agressively bad almost take it poorly and can't take feedback positively .

Interviewing is not 100% representative of on job behaviour, however this helps a lot in filtering out

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

#174
post #115

Earlier quoted context omitted.

I'm curious to know if you or anyone else reading this has run into the opposite problem. Or maybe I'm just "that guy" although I am reasonably certain that I am not. As a rule, so far throughout my 5 year career as a full stack web developer, my coworkers have neither understood or cared about what clean code entails. I don't berate, I don't criticize, I've taken to mentioning it once and then doing my utmost to nev…

It’s possible there are things you are still learning, or context you are missing. You sound still early career enough that the years will likely mellow you out and teach you to better appreciate the ups and downs of building things fast. You know what’s worse than no abstractions? The wrong abstractions.

Oh c'mon graybeard, you can't honestly be defending 1500 line components right now can you? It's not even a matter of abstraction choice, it's a matter of simple hygiene.

You know what's worse than the wrong abstractions? Copy and pasting your inline-styled div with a zIndex of 99,999 for the fifth modal in a row because you can't be assed to write a damned display component in anticipation of the next time you'll need to put a Modal together.

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

#177

> 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. Tell me about higher goals, training rookies and all that — I know you’re simply too full of themselves. And if you try to tell me that you learned to defeat that feeling (however it manifests in you), then I must be a pink unicorn. I r…

Sometimes I’ll look over PRs early on, notice the entire approach is bad, and leave a comment. People often got annoyed, they would say their PR isn’t ready yet. That’s fair, I kind of understand, my intention was to just save them time going down an incorrect path though, because I know it’s going to be difficult to convince them later they need to rework days of work. Not sure what the solution is.

If team work isn't in the culture at your place it's very understandable they would react like that. If they don't see the benefits at your place and they've also only had bad experience with that at their previous places it's the natural defense mechanism.

You could do the first step for example. Put up your own stuff for early on RFC. Invite them to work collaboratively on it with you and give early feedback and see how you react. Basically: be the role model and let them follow.

Not guaranteed to work but it's one way to start some of it.

Sidenote: most teams don't actually do team work. It's a bunch of people thrown together that work on more or less loosely related stuff but everyone is out for themselves. It's a matter of the environment they have to work in in most cases. Individual metrics driven productivity culture. You can't expect someone to do good team work and collaboratively come up with the best approach when their incentives from management's side is to get as many PRs merged as they can to get that bonus and a good end year rating etc.

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

#178
post #115

Earlier quoted context omitted.

I'm curious to know if you or anyone else reading this has run into the opposite problem. Or maybe I'm just "that guy" although I am reasonably certain that I am not. As a rule, so far throughout my 5 year career as a full stack web developer, my coworkers have neither understood or cared about what clean code entails. I don't berate, I don't criticize, I've taken to mentioning it once and then doing my utmost to nev…

Couple things about this, because there are levels. First, understand to be a successful engineer you need to be a bit pedantic, so start by forgiving yourself and take a deep breath. Once you become competent enough to identify clean code, understand that your perception of clean code is colored by your own experience and current mental context. As you learn, you will undoubtedly be aghast at your own code that you…

> forgiving yourself and take a deep breath

I appreciate the reminder and the helpful tone of your comment in general!

> As you learn, you will undoubtedly be aghast at your own code that you wrote at any time before 6 months ago.

Just checked, and my code from 6 months ago looks identical to what I write at work. My programming style went through a few different phases but its variability has mostly leveled off since I've started writing in a mostly-functional style.

> It's not purely about technical strength

It's simple stuff like putting together a base Modal display component for re-use instead of copy/pasting that div with the inline-styled zIndex of 99,999 for the umpteenth time.

> As you move up the seniority and scale ladder to larger projects and architectures

I hope to side-step a lot of those pitfalls by exiting the ladder altogether and starting my own company where I take a fine-toothed comb to the process of onboarding new hires. Time will tell if the demands of scaling a company end up sidelining my desire for good hires, but software is still a somewhat nascent field, so the sky's the limit if you ask me!

> the human brain is weak, and it's hard enough to not get caught in the wrong local maxima without facing up to the immense challenge of choosing between global maxima in the incomprehensible problem space where software meets human needs in the hybrid meat/mental/cyberspace ecosystem where they exist and evolve over time.

This is a good way of putting it and it's why it's the problem I've chosen to work on for my first product as a startup founder. I call it Pidgin, and my vision for it is a GUI tool for refactoring and even writing code in a more deterministic and reliable way. I spend my mornings before my day job working on it. I think the fact that I think about code quality intensely at all hours of the day probably contributed to the emotional tone of my initial comment. :)

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

#179
post #75

> 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. Tell me about higher goals, training rookies and all that — I know you’re simply too full of themselves. And if you try to tell me that you learned to defeat that feeling (however it manifests in you), then I must be a pink unicorn. I r…

Same here. For me, code review is a good time to share knowledge and help other people. If a problem often comes up, I usually try to see if a tool can solve this. I'll admit that it can be really hard to know what level of tolerence people have for nitpicks and things like that, and at which point you're starting to sacrifice team spirit/people's feeling for small things.

That's why I love pipeline integrated scans that point out issues like excessive cognitive overhead (big fat if/else waterfall with loops everywhere) or "code smells" so the team doesn't get bogged down in munitia during code reviews. If someone needs help getting a piece of code tested to 100% or resolving a code smell they can reach out or bring it up in a standup.

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

#180

Earlier quoted context omitted.

Strange, I’m on a team rn with people who just approve everything. I’m craving some constructive feedback.

It might mean you're doing it basically correct, or it might mean you're touching parts that people don't care about much. The second is probably more common. (It might also mean your team doesn't care about anything any more, in which case look for a better opportunity, unless you want to just cruise along for a while for whatever reason, in which case turn into a bare minimum performer like the rest of your team).…

Thank you! I agree with so much in this, it really strikes the right balance of clean code vs productivity.

One of my peeves is a review that points out a bug/incorrectness without offering proof, or suggesting the fix/correct way. The reviewer might observe a code smell, but it's so much better dealt with a question-comment, e.g. "did you try?" vs "this looks wrong".

I generally aim to make every comment a question ("can we..."), and not make assumptions that the author didn't think of something already. Unless I just stating an objective fact that is clearly unknown e.g. "this duplicates library function x...".

Post reply on HN