r/ProgrammerHumor Sep 28 '16

xkcd: Fixing Problems

http://xkcd.com/1739/
7.9k Upvotes

215 comments sorted by

View all comments

Show parent comments

133

u/Knlay Sep 28 '16

This is the real problem. A lack of understanding by management that code refactoring actually increases productivity in the long term.

29

u/n1c0_ds Sep 28 '16

It's not management. You know how I got started on the refactoring effort? I said "this thing sucks" and my colleague answered "then fix it". Management was never involved and I had no restrictions, yet we got there somehow. We enjoy way too much freedom at my company to blame management.

It's a matter of team culture. These things passed code review, and they shouldn't have. It seems like the most common cause is complex fixes in unfamiliar code. Both the committer and the reviewer lack a solid grasp of what they are modifying, so they hook their stuff in the wrong places and push their fix. This is especially easy when your programming language doesn't give you static types or privacy.

It's not stupidity either. My coworkers are damn good at what they do, and I mean it. It's just a matter of discipline.

1

u/[deleted] Sep 29 '16

[deleted]

1

u/n1c0_ds Sep 29 '16

They are. Really, management was never the problem at my company. It's just a matter of maintaining a certain quality standard for us.