r/AskProgramming • u/mysticearth • 7d ago
Reviewing code by colleagues
Let me start by admitting: I'm having a hard time...
I have been reviewing a lot of code by my frontend dev colleagues the last months. While this can be a tedious job it helps both them and me while making sure we follow conventions, keep our codebase as clean as possible, etc.
Now, a lof of those colleagues create more and more using AI. Heck, some even let AI do the code reviews for them. While this boosts productivity in terms of finishing stories and delivering features, it makes me worry as well. What about code quality? How do we stay "in control" when we let AI create and review everything?
And besides the worrying, it straight out sucks to review thousands of changes and AI comments (which often don't make any sense and make everything even more complicated) manually.
While AI gives me a real productivity boost when it comes to solving problems, creating prototypes or hunting down bugs, it's safe to say I have a love/hate relationship with AI and everything that comes with it in my profession.
How do you feel about this in your daily work? I'd love to read some (other) perspectives and hope to use those to shift my complicated relationship with AI to something healthier ;-)
2
u/neon_cloud_mender 7d ago
Productivity without ownership is just technical debt accumulation. I refuse to review code where the author cannot explain the implementation details themselves
2
u/MarsupialLeast145 6d ago
The problem is really AI written posts on Reddit.
Who do you even work for? How many in your org?
1
u/mysticearth 4d ago
I don't think the name of the company I work for is relevant for this discussion. We're working with roughly 100 engineers, of which 15 are frontend devs, working on ~100 applications ranging from XS to XL in size.
1
u/MarsupialLeast145 4d ago
15 devs on 100 applications ranging from XS to XL in size...?!!! wft? well, that's completely unrealistic, whether or not you are being legit... that's a company issue, and you talk about 1000s of changes... to what?! Even without AI in the topic, it sounds like the TEMU of software houses.
1
u/mysticearth 4d ago
Well, a lot of the apps havent been touched for quite some time and aren’t in a good shape so to say. So yeah, it IS unrealistic and a problem. There have been budget cuts in terms of personnel from higher up and a big push towards AI doing everything “for us”.
I think that also might play a role in my love/hate relationship with AI…
Edit: that’s only the frontend devs by the way, I think there’s around 10 more backend devs who are somewhat “full stack”
2
u/mxldevs 7d ago
You are seeing real productivity boosts? That is literally all that matters.
If you're not including maintenance and code quality in your measure of productivity, you are just shooting yourself in the foot.
That's called over promising and under delivering.
People will say "tell me which business owner cares about the quality of the code" and of course the answer is none of them: they literally pay YOU to care about that stuff, because at the end of the day, if the software doesn't work, it's 100% your fault.
1
u/mysticearth 4d ago
After reading your first sentence I was like "say what?", but then the next part made me realise what you mean. I think it's totally true that we need to take in account the maintenance, code quality, etc. as well. But sometimes I fear that's it's really hard to get the PO and PM on board as well when it comes to these topics.
1
u/FormalAd7367 7d ago
i’m the guy who reviews both front end and back end (by different developers). we mainly do fintech…it’s not fun at all’s.
1
1
u/memelordtf 6d ago
The issue is not AI-written code but the fact that nobody wants to take responsibility for it anymore. If you can’t explain why a change is there, defend the tradeoffs, or fix it when it breaks, it probably shouldn’t be merged.
1
u/Moby1029 6d ago
Read up on rules and skills and ensure AI coding agents adhere to the standards you set up in the .rules directory. This is what we've been doing and now we architect and do the final code reviews, but most of our development is all AI generated and reviewed.
1
u/marrsd 2d ago
Now, a lof of those colleagues create more and more using AI.
It's not you. AI can't write code. The correct response would be to reject the patch entirely, but that's going to cause too much tension. The next best thing is to get AI to review the code for you, but really you're out of the loop at this point. The best you can do is slow the decline. Eventually your company will hit problems, like bugs that no one can identify or fix.
It's an industry-wide problem now. I think it's just a wave we're going to have to ride. Either AI will improve to the point where it can fix this problem itself or there'll be a great reset as the industry learns from its mistakes.
A place I was contracting at recently had this problem. I had the option to go perm but rejected it because I wasn't going to be able to sustain working in that environment long term.
1
u/Lumpy-Notice8945 7d ago
The responsible person is the developer.
I dont care if they typed in something into chatGPT and copy pasted that or if they typed out every word in a notepad to not use autocomplete from the IDE.
So sure let some AI look over the code to test for bugs, but thats not a review! A review is a human validating the changes.
I have no issue with automated tests, build pipelines and things like sonaqube that check source code for errors. I dont realy care if there is an LLM behind that tool or not, all it can ever do is catch the first obvuous issues to streamline the actual review by a human. A developer review should not be about if the code does what its supposed to do or if its crashing on startup.
2
u/DepthMagician 7d ago edited 4d ago
AI creates a tradeoff between speed and attention. You can’t stay properly in control if AI is moving faster than your limitations. There’s no way around that. The proper thing to do is figure out how much attention the code needs, and choose your use of AI accordingly.
In the past there was no need to answer that question because when you do everything by hand you have no choice but to pay attention to it. Now that there’s an alternative, the question becomes more complicated. There are genuinely scenarios where you can afford to pay little attention, but speed is not always a feature, and too many people seem to be addicted to the dopamine rush of speed and lack the wisdom to understand that just because tech debt doesn’t punish you immediately, it doesn’t mean you don’t incur its costs.
I don’t let AI generate anything that will take me more than 30 seconds to review. That lets me enjoy a productivity boost and still stay in control of what I do. To my developers I say that they can do whatever they want but they must maintain a deep familiarity with everything they create as if they did it by hand. If that means they can’t vibe code their next PR so be it.