Comment by capableweb
2 years ago
I wrote it in past tense, it's based on actual situations :) If you don't believe what I write, I guess it doesn't matter what I write now. Regardless.
One simple example that I've had to reject more than once.
- Function 1 does something
- Developer needs something like Function 1 but minor change
- Developer starts typing name of function which has a similar name to Function 1, but again, minor difference
- Copilot helpfully suggests copy-pasting Function 1 but with the small change incorporated
- Developer accepts it, commits and sends the patch my way
Rather than extracting the common behavior into it's own function and call that from both of them, refactors which Copilot doesn't suggest, the developers is fine with just copy-pasting the function.
Now we have to maintain two full slightly different functions, rather than 1 full functions + 2 minor ones.
Obviously a small example, and it wouldn't be worth extracting it the first time it happens or on a smaller scale. But once you have entire teams doing something like this, it becomes a bit harder to justify copy-paste approach, especially when you want the codebase not to evolve to complete spaghetti.
And finally, I'm not blaming the tool, it's not Copilots fault. But it does seem to have made developers who rely on it think less, compared to the ones that don't.
No comments yet
Contribute on Hacker News ↗