Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

This question already has an answer here:

I've been working in the same software development department for a few years now. In that time, the average stay of a developer has been 6-9 months. A handful have been around for over 2 years, but the majority of our 20 or-so developers come and go at a relatively high rate.

As a result, the majority of our projects have become maintenance nightmares. Contractors will come in, code a few patch releases, and leave.

Our department has development guidelines (we do TDD) but they aren't enforced.

Recently, I've been pushing for our department to produce more maintainable code. I've been asking for mandatory code reviews and mandatory TDD. Management fully agrees with me... in theory.

In practice TDD always goes out the window. The justification is always that, in our domain, we need to deliver NOW.

I keep going on and on to colleagues that we're just digging a hole for ourselves, and that our current approach to software development is costing our department a lot of money... but it seems to fall on deaf ears.

What can I do to get my colleagues to see the value of code maintainability? How can I explain that short-term wins without a long-term vision is not sustainable?

share|improve this question
Are you sure the problem is with your colleagues and not with management? –  user16764 Apr 12 '13 at 17:28
Is the company financially stable or is it still trying to get to the point of being profitable? There is something to be said for the maturity of the company that could be a factor here. –  JB King Apr 12 '13 at 17:55
JB King, The company is more or less financially stable. There have been pressures from upper management to do things on a budget, but this is precisely why I think proper TDD and code maintainability is important. user16764, I was including the dev manage in the term "colleagues." –  MetaFight Apr 12 '13 at 18:35
if there is a high turnover rate there is a reason for it, ask the people leaving why they are or what would have made them leaving less likely –  ratchet freak Apr 12 '13 at 20:47
I saw things like that during my contracting days. It seems to me the real problem is the high turnover, and that is caused by a management style, starting from the top, that doesn't actually value its people. I could always tell, just by sizing up the CEO, whether this would be a good company to work for. –  Mike Dunlavey Apr 12 '13 at 20:49
add comment

marked as duplicate by gnat, Martijn Pieters, Karl Bielefeldt, GlenH7, Bart van Ingen Schenau Apr 13 '13 at 6:50

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

3 Answers

up vote 15 down vote accepted

It's not your colleagues that you need to convince.

If management truly agreed with you, they'd be enforcing the code reviews and TDD. As it is, they're just nodding their head to make you stop bothering them.

I see two options here:

  1. Make a pitch to senior management about how high employee turnover and lots of client facing bug reports are costing them money. Include in your pitch a viable solution that involves enforced code reviews, TDD, etc. Wrap a time frame around it and promise to deliver. They might make you a manager in charge of fixing it.

  2. Leave. If you know it's going to collapse, why stick around?

share|improve this answer
Thanks for your input. I have already brought up all the points in option a) at one point or another, but maybe you're right: Maybe it would have a strong impact if I put all the information in a quick potent presentation. Lately I've been considering option b) a lot. My biggest worry though is that I'll encounter these same problems no matter where I go. I feel very lucky to work in my current domain (it's F*in cool!), so I'm reluctant to leave. I'm also reluctant to put up with a bad work environment just so I can impress the ladies ;) –  MetaFight Apr 12 '13 at 18:41
add comment

I see this happen a lot when one developer works on a project exclusively for a long period of time. They know where the pitfalls are and how to work around them, and so they generally don't care that they exist. The number one way to convince developers to employ common coding standards and best practices is to get them to work on other developer's code from time to time. They will see pretty quickly the value of self-documenting code, proper exception handling, cleaning up dead code, etc. Do this once or twice and your fellow developers will be happy to adopt these practices.

With managers, it's usually a different story. Good managers will respond to complaints from developers and proactively look for ways to improve your company's coding practices. Bad managers won't care, as long as the product gets out the door on time. For these types of managers, you will have show them what's wrong with how you're doing things. Explain that it takes twice to three times as long as it should to train a new developer, or that it takes a days to find bugs which could be fixed in a matter of minute, all because the code base is a mess. If possible show real, concrete cases of the costs associated with poorly maintained code.

share|improve this answer
add comment

Screw explaining things to people.

It might be easier to get management/other devs onboard with some type of Continuous Integration. Then, if the tests don't pass, the code doesn't ship. End of story.

share|improve this answer
Having tests that pass does not make the code more maintainable. –  Bernard Apr 12 '13 at 23:22
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.