Code quality at work

Started by
22 comments, last by smr 7 years, 5 months ago

Problems with work code:

  • Deadlines: Whether it's someone yelling at you or you just being afraid you won't get something done in time, there's almost always a point where you'll throw together horrendous code you think you'll fix later and then 6 months later, hey it's still there!
  • Differing Opinions: Code review can be good but what do you do when someone just disagrees with you on what is nice looking code? Working on your own project that isn't ever a concern since you are the master of the universe.
  • Being Programmers: Most programmers want to try and improve, they'll write code for awhile then have that moment of "man this looks terrible, I should write it differently next time." Or they end up refactoring it right then and there, sometimes making a bigger mess.
  • Grandfather Clause: Often you just end up stuck with very outdated code and have to hook up some horrible monstrosity to communicate with it. Usually a bigger problem at work vs home, where you can allow yourself to redo large systems.

That said you can write some pretty bad home code too, I hate to admit it but often trying to adapt new coding patterns to make my code more pretty or readable or accessible has just ended up making it more of a mess to me. I know everyone around here tends to throw bricks at each other over code style but usually the most important rule is that something works.

Advertisement

Problems with work code:

  • Deadlines: Whether it's someone yelling at you or you just being afraid you won't get something done in time, there's almost always a point where you'll throw together horrendous code you think you'll fix later and then 6 months later, hey it's still there!
  • Differing Opinions: Code review can be good but what do you do when someone just disagrees with you on what is nice looking code? Working on your own project that isn't ever a concern since you are the master of the universe.
  • Being Programmers: Most programmers want to try and improve, they'll write code for awhile then have that moment of "man this looks terrible, I should write it differently next time." Or they end up refactoring it right then and there, sometimes making a bigger mess.
  • Grandfather Clause: Often you just end up stuck with very outdated code and have to hook up some horrible monstrosity to communicate with it. Usually a bigger problem at work vs home, where you can allow yourself to redo large systems.

That said you can write some pretty bad home code too, I hate to admit it but often trying to adapt new coding patterns to make my code more pretty or readable or accessible has just ended up making it more of a mess to me. I know everyone around here tends to throw bricks at each other over code style but usually the most important rule is that something works.

Yep, welcome to the world of people giving you money to write code.

if you think programming is like sex, you probably haven't done much of either.-------------- - capn_midnight

My code at home is far better than what I work with. That's because at home I have as long as I like to refactor things or do them the right way. In the real world (or at least the part that I inhabit) the publisher doesn't pay to make your code look nice and they often don't care if the code is usable for future projects either.

This is also true for me. Managers have different concerns then most developers, they need respect budget and deadlines. Some are just a bit too shortsighted sometimes. We are spending more time dealing with poorly organized code on a regular basis then it would have taken to just fix some things in the first place. At some point, you accumulate so much problems that it becomes impossible to even do a simple modification and then, you need change big things.

We think in generalities, but we live in details.
- Alfred North Whitehead

Don't you feel when you're working on your games, that you make high quality code compared to the shit you see everyday at work ? I'm a PHP developer and literally EVERY project I worked on had suber-shitty code, with retarded useless/duplicated/unreadable parts. I feel so bad for the developers who made that. I know sometimes the deadlines are shorts and you must rush it. But it feels really tiring to see the same shit after working in 5 different companies. Don't you think it happens because of employers thinking developement can be done by any beginner ? Developer is often associated with "code monkey" (at least in France) and employers doesn't seems to understand that there are huge quality differences between the complete noob who made his personal website and professionnals with 5+ years of experience...

I find that most people -- myself included -- think just about any code written by someone else is shit. It's just a lot easier to write code than to read it.

As far as employers are concerned, they don't care about your code unless it's not working, or costing them money.

This topic is closed to new replies.

Advertisement