In college, on the first day of orientation, someone in my class bragged that they wrote 50,000 lines of code for a game that was similar to tic tac toe, emphasizing that he “wrote a lot of code”. A TA told him that it wasn’t a sign that his program was decent and that it really didn’t seem like it should take 50k lines of code to make something as simple as his game.
He dropped out after the first week of intro to programming.
I wouldn’t say PR size is a bad metric, you usually just need yo read it the opposite of how sloppers do it, i.e. the most productive PRs are short and focused.
Yeah, I’ve been guilty of coming up with “cute” solutions that are extremely optimized and concise, but you needed to take a hundred times as long to work through what was going on.
Usually I would put an explanation comment, but sometimes a less optimized solution is the better option for readability sake.
I’m not saying it’s a good individual metric. In fact, applying individual metrics to developers (or most workers really), will only land you in Goodhart’s hell.
But as part of holistic operational health tracking, it’s a useful team level metric, as there is ample evidence that shorter PRs tend to result in less operational issues. And, of course, this is only valid if you don’t try to tie financial rewards to it, otherwise people will forget that PR size is a proxy measure for how easy changes are to review and rollback.
Hah, if those pesky devs think that they can play the system by just rolling up the code into a single line they got another thing coming - we’re actually tracking PR character count, NOT LOC like some other companies!
Number of lines of code written is a shitty metric to measure productivity.
In college, on the first day of orientation, someone in my class bragged that they wrote 50,000 lines of code for a game that was similar to tic tac toe, emphasizing that he “wrote a lot of code”. A TA told him that it wasn’t a sign that his program was decent and that it really didn’t seem like it should take 50k lines of code to make something as simple as his game.
He dropped out after the first week of intro to programming.
That’s nothing, I wrote the code to return if the input is even or not in 1M lines of code.
If 1 no else if 2 yes else if 3 no…
Are you working with 20 bit integers? You’ll never get it down to a million lines like that…
There’s a million lines of If >4096, subtract 4096
Then a quick lookup case statement for whether the remaining number is even.
If you want to learn natural language processing, this is actually a fun example to generate code for.
Exactly…
And yet I experience it so often. That or “effort points” as the metric being used to determine who all stars are.
Either as a metric just encourages gaming of the system:
I’ve been on teams that on the surface didn’t have these metrics matter, but the top effort points achiever got bonuses on the DL.
What did you do?? You refacted the code and now it’s better organized but you overall got rid of lines?
I’ll set up a PMD meeting to help you out of this problem, but fair to say don’t expect a raise or a bonus this year.
I wouldn’t say PR size is a bad metric, you usually just need yo read it the opposite of how sloppers do it, i.e. the most productive PRs are short and focused.
PR size is an awful metric. The bigger the PR, the less reviewable it is.
Yes, that’s what the comment said — smaller PRs are better.
PR size is still an awful metric. It should be within bounds but it should never be an actual metric. Treating it as a metric is an idiotic idea.
Then Devs focus on minifying the code into an unreadable mess
Yeah, I’ve been guilty of coming up with “cute” solutions that are extremely optimized and concise, but you needed to take a hundred times as long to work through what was going on.
Usually I would put an explanation comment, but sometimes a less optimized solution is the better option for readability sake.
I’m not saying it’s a good individual metric. In fact, applying individual metrics to developers (or most workers really), will only land you in Goodhart’s hell.
But as part of holistic operational health tracking, it’s a useful team level metric, as there is ample evidence that shorter PRs tend to result in less operational issues. And, of course, this is only valid if you don’t try to tie financial rewards to it, otherwise people will forget that PR size is a proxy measure for how easy changes are to review and rollback.
Hah, if those pesky devs think that they can play the system by just rolling up the code into a single line they got another thing coming - we’re actually tracking PR character count, NOT LOC like some other companies!
deleted by creator