DEV Community

Why junior devs should review seniors' commits

Sami Pietikäinen on April 08, 2018

Code reviews are a great practise to find mistakes, potential bugs and other issues overlooked by the code author. Reviewing improves the overall c...
Collapse
 
jballanc profile image
Joshua Ballanco

This is so essential, I loath to think that there are teams out there where juniors are not reviewing the code of more senior members!

My very first programming job was working with a team that was in charge of a very large server product that involved everything from HTML+CSS and Ruby on Rails right down to video codecs and network protocols implemented in C/C++. When I was hired on, I had assumed it was primarily due to my experience with Ruby, so I was caught off guard a bit when one of our senior-most developers called me into his office the first week to review a commit he had just written for the work distribution algorithm that involved BSD socket APIs. I will admit, as the article here mentions, that I probably benefited more from the interaction, as I was about as useful in that code review as a Rubber Duck, but having that experience (and on the first week) cemented in my mind that we were one team and that, although I might have been hired for my Ruby skills, I was going to have to bear the same responsibility for our product as everyone else.

From that point on, I worked harder on that project than almost any other project I've worked on since.

Collapse
 
samipietikainen profile image
Sami Pietikäinen

Thanks for sharing your story! It coins exactly the point I was trying to make. It also shows a great professionalism from that senior developers part (probably one reason he/she was a senior in the first place) which, it seems, had a pretty profound effect.

Collapse
 
derekjhopper profile image
Derek Hopper

I agree with you and thought the same thing. It's one of those intangible traits all senior developers should have. When I started as a developer, you tend to think senior means writing the most/best code and that's it. That should be a small part of it, absolutely. However, if you're not making those around you better, you're not being the best you could be.

Thread Thread
 
jballanc profile image
Joshua Ballanco

It's the classic case of: a 10x developer doesn't produce 10x the code, they influence the 10 developers closest to them to produce 2x the code.

Collapse
 
aghost7 profile image
Jonathan Boudreau

This is how we do things at my work - juniors can review senior dev's pull requests. It helps to break down walls and prevent authority from piling up.

Collapse
 
hdennen profile image
Harry Dennen

We've just started doing this as well. Seems to get a bit competitive at times though.

Collapse
 
aghost7 profile image
Jonathan Boudreau

I'm experiencing the same thing, but I think its worth it.

Collapse
 
jaymeedwards profile image
Jayme Edwards 🍃💻

Love it. Great way to challenge traditional power structures and get people working together better.

Collapse
 
thebouv profile image
Anthony Bouvier

This is absolutely necessary to do. You're not going to be magically bug-free just because you're more senior. Hell, hubris can breed bugs in your code just as easily as naiveté.

Collapse
 
realedwintorres profile image
Edwin Torres

I never underestimate a new developer's ability to find bugs in my code. We all make mistakes. The more eyes on our programs, the better.

Collapse
 
mfcarneiro profile image
Matheus Felipe

Great article and idea!