I'm the tech lead for our small and growing tech team. One of the first people we hired was a mid-level engineer and a little new to the full software-engineer setup: best practices, coding standards, automated test writing, etc...
Some of the early things this person worked on were less mission-critical, and so I was not a stickler for best-practices in the beginning, to give them time to catch up. Over the months though I've been slowly encouraging best practices and raising the bar, and have always been very clear about my long-term expectations (full test coverage, strict adherence to coding standards, etc). This person has recently started working on more critical components, and so I'm now doing daily code-reviews with them to make sure that everything is completely up-to-spec before it is "finished".
The result of this is that I have sent their code back for more work a number of times. Some of it has been for outright bugs (and subsequently to write the missing tests that should have caught the bugs), and some of it has been more about future-proofing or changes that will make the code easier for others to work with in the future. Today in particular I sent the same piece of code back 3 or 4 times: initially for some details that were missed, and then more because the changes introduced to address my initial concerns had their own issues.
Probably not surprisingly, this person is clearly starting to feel frustrated with this process. To be clear, my own code reviews aren't simply "this is wrong, fix it" but involve a good amount of detail explaining what the problem is, why it will cause problems in the future, and why it will be better for all of us to get it right the first time around. I'm trying to help the person see the importance of getting this right from the beginning, even if it takes more time as a result. From my perspective (I've worked with a lot of large code bases in the past), these things are simply necessities to manage our systems in the long term. From this person's perspective though, I'm sure I'm seen as being overly picky.
As the tech lead of course, I set the standards, and I don't intend on changing them. However, I would like to help this person get past their frustration and see these things as I see them: if we don't get the obvious stuff right now, it is simply going to be that much harder for everyone a month from now when something needs to change.
It occurs to me that this may be a sign that I'm not providing sufficient (or good enough) training. I also may have transitioned from "Here are things to keep in mind" to "Let's get everything right before we move on" too quickly. With that in mind, here are some specific questions:
- How can I help my coder have a more positive perspective about me sending their code back for changes frequently?
- Is this a sign that I am doing other things wrong?
- Any suggestions on how I might smooth out this transition a little better?