News for hackers. Stuff that matters.
Re:Technical debt as an opportunity to accumulate technical ... by itchyouch on Monday August 15, 2016 @04:31PM (#12293181)
Or we can not look at tech debt as debt but as a unhedged call option:

http://higherorderlogic.com/2010/07/bad-code-isnt-technical-...

From the article:

Call options are a better model than debt for cruddy code (without tests) because they capture the unpredictability of what we do. If I slap in an a feature without cleaning up then I get the benefit immediately, I collect the premium. If I never see that code again, then I’m ahead and, in retrospect, it would have been foolish to have spent time cleaning it up.

On the other hand, if a radical new feature comes in that I have to do, all those quick fixes suddenly become very expensive to work with. Examples I’ve seen are a big new client that requires a port to a different platform, or a new regulatory requirement that needs a new report. I get equivalent problems if there’s a failure I have to interpret and fix just before a deadline, or the team members turn over completely and no-one remembers the tacit knowledge that helps the code make sense. The market has moved away from where I thought it was going to be and my option has been called.

Re:Technical debt as an opportunity to accumulate technical ... by crdb on Monday August 15, 2016 @07:44PM (#12294428)
More like selling a put: you're hoping it expires out of the money, but if volatility goes up, it will be expensive. Upside is limited and short term, downside potentially unlimited and in the long term, so if your discount rate is high (due, perhaps, to low cash reserves) then the NPV of the trade still makes sense.

People who sell a few puts get away with it for a while, but make it your business and you better be too big to fail.

If everybody is selling puts and levering up, you better do it too or you'll find yourself out of a job. And if volatility increases, everybody is exposed at the same time so you won't get personally blamed anyway, and your career will be just fine.

Re:Technical debt as an opportunity to accumulate technical ... by taeric on Monday August 15, 2016 @09:57PM (#12295004)
I think you are underselling the upside, to be honest. History is littered with massive successes that are essentially technical debt, as software folks call it. AC/DC power is actually a fun case study in that regard.
Re:Technical debt as an opportunity to accumulate technical ... by crdb on Monday August 15, 2016 @10:55PM (#12295237)
But the success is not directly inherited from technical debt. Technical debt bought time that enabled the success to happen (maybe before the company ran out of money, or allowing it to launch months ahead of the competition), but the company would not have failed if you somehow built it "properly" and otherwise met those constraints.

In other words, you can rationally make the decision to take on technical debt if it allows you to meet those constraints. It isn't a black and white decision.

It seems obvious to say this, but I know plenty of founders and investors who have had success (survivorship bias - if they hadn't they wouldn't be investors/founders) with the technical-debt-and-grow method and therefore apply it to every problem.

Re:Technical debt as an opportunity to accumulate technical ... by taeric on Monday August 15, 2016 @11:14PM (#12295303)
Any way you formulate this, it is entirely possible that taking on technical debt is required for a largely unbounded success.

It may be a couple of steps removed, but it is still a direct line. Time to market is a vital metric for everyone. Anything that can help hit a tight time to market can add to the success of a company.

Can you reformulate it so that time to market was irrelevant for success? Only if you are comfortable with what is likely a bad model.

Re:Technical debt as an opportunity to accumulate technical ... by crdb on Monday August 15, 2016 @11:56PM (#12295440)
> it is entirely possible taking on technical debt is required for a largely unbounded success

> Time to market is a vital metric for everyone

I disagree with the first statement (I know plenty of exceptions, enough to statistically consider that it is false) and disagree with what you imply with the second. Google launched against 5-6 strong, established search companies. Copying the then-strategy of paid listings was not going to work, and their technology had to be ready before hitting the market. Theranos is an example where the technical debt did not pay off. Time to market was not as important as getting the tech to work.

I had a long meeting/debrief yesterday with a C-level from a freshly failed, large internet group. Their CEO and CTO's strategy to get out of the hole was to technical-debt-and-grow a dozen products in parallel in the hope one sticked; whilst several stuck, they did not have the expertise or willingness to do the work to stop the products from breaking, and the company failed by running out of money (which, due to technical debt stopping the accountants from having any visibility, surprised them all).

I consider their failure to be entirely due to the idea that technical debt is required for a large unbounded success, which was like a religion for the CEO and CTO. Had they gone "private equity" (cut headcount, focus on core business, invest time in cleaning up) they might have survived long enough to become profitable again.

Many business founders will not have the resources (reputation, money, or even just hustle, EQ and maturity and leadership) to get a good technical co-founder and will have to either take shortcuts, or reconsider their decision to start up without said resources.

Re:Technical debt as an opportunity to accumulate technical ... by taeric on Tuesday August 16, 2016 @10:37AM (#12297714)
You are shifting my claim from it being a possibly necessary criteria, to it being the sole criteria. Worse, you are shifting my claim to be that technical debt somehow guarantees success.

Neither of these are my assertion. I simply assert that time to market is a vital metric. If hitting a vital time to market means making some tradeoffs (what we now call technical debt) then, so be it.

Take your examples, do you really think that Google did not make some tradeoffs? Having seen some of their products (I'm looking squarely at the pieces of crap that were my early phones from them...), I can confidently say they make rash decisions all of the time.

Now, there is a silly double speak that we have in the industry where we say "technical debt" when we really mean just poor work. There is a lot of conflation in the world where these two should not be mixed.

Re:Technical debt as an opportunity to accumulate technical ... by simula67 on Tuesday August 16, 2016 @02:21AM (#12295856)
I wish this was true, but we can see that it is not.

Take a look at successful programming languages. Languages like PHP, Javascript are hugely successful, despite universally acknowledged to be terribly designed. In open source world, despite having very poor reputation for code quality, projects like Wordpress, MySQL are more successful over supposedly well written projects like Postgres.

One exception to the rule is Perl, which lost out to Python as the de facto scripting language over time ( Python is supposedly better designed that Perl 5 ). But these are exceptions, not the rule.

Re:Technical debt as an opportunity to accumulate technical ... by throwawaymsft on Tuesday August 16, 2016 @02:51PM (#12299674)
The max risk is known when selling a put. If I sell a put for 100 shares of Apple at $95, the most I can lose is 9500 (minus the premium I earned).
Re:Technical debt as an opportunity to accumulate technical ... by crdb on Tuesday August 16, 2016 @06:38PM (#12301173)
The value of the option will rise with volatility. It is more apparent if you delta hedge leaving you with a net gamma position (i.e. hoping for quieter or more volatile markets depending on whether you are short or long gamma). Selling an option puts you in a short gamma position whether it is a put or a call.

The subtlety is that volatility falls slowly as prices rise AND rises much faster as prices fall. So (equity) options become much more valuable when things go badly. Check the S&P500 vs VIX and watch how the VIX explodes upwards with each market correction then slowly drops back as prices rise.

The metaphor can only go so far. He does not specify the underlying in the article but the mechanics described imply the company's health. If the bet is correct, the company will do well and "volatility will fall" making the option less valuable. You could say the impact of the damage made by technical debt is less important because you have more resources to deal with it (this is how spaghetti ball codebases start, but in the medium term it holds).

On the other hand, if the company does badly (fundraise fails, product does not grow as expected) the relatively small payoff from technical debt is exponentially more expensive and might well wipe out the tech side or slow down development enough to allow the competition to win faster. This is why I say the damage is "potentially infinite" (where infinite is used colloquially rather than formally).

In particular, an unhealthy company with a lot of technical debt will rapidly see its top technical talent bleed and find it hard to hire (I'm not theorising - I've many times heard developers who interviewed at well known places tell me afterwards "I liked the pay, the people and the brand, but the codebase was a mess and life is only so long"). Thus the damage done is rapidly exponentially higher than the reward (traders will refer to "convexity" or non-linearity in the model, convexity being the degree of curvature) throwing you in a death spiral.

You can even fit in the volatility smile: as more experienced developers ("the market") have in aggregate picked up on the convexity of the technical debt trade, they are more reluctant to take it on the more improbable the payoff is - that is, they compensate for the kurtosis of the return distribution (which is why buying deep out of the money options all the time hoping for 2008 to happen is a bad strategy).

I recommend Nassim Taleb's Dynamic Hedging which despite the dry title explains these ideas quite intuitively.

Re:Technical debt as an opportunity to accumulate technical ... by yelnatz on Monday August 15, 2016 @06:12PM (#12293893)
I agree with this. Tech debt really is very similar to how selling call options work.

Unfortunately, not a lot of people know how options work, so now you have another problem of explaining how that works.

Re:Technical debt as an opportunity to accumulate technical ... by dwaltrip on Monday August 15, 2016 @04:53PM (#12293342)
Totally agree. Unfortunately, it's a market with low liquidity and opaque fundamentals, so black magic reigns supreme.

The greatest difficulty is trying to predict how the product will evolve, and thus how the software must also evolve. We should always be thinking about how the relevancy and requirements of each component of source code may change in the future: next month, in 6 months, 2 year from now, etc.

To better evaluate the risk of each call option, there needs to be a strong, coherent, and tangible vision of what the product should be. This vision should be internalized by the entire team. There also needs to be a healthy, forward thinking dialogue between designers, product owners, and engineers.

Re:Technical debt as an opportunity to accumulate technical ... by ptype on Monday August 15, 2016 @04:46PM (#12293291)
Honestly, this seems like a stretched comparison to me. How many managers understand options? And what is even the underlying for your call option? Why would it be a call option and not a put option?
Re:Technical debt as an opportunity to accumulate technical ... by kafkaesq on Monday August 15, 2016 @07:46PM (#12294438)
That's precisely the point - the reason so many companies fall into the trap of technical debt is that they not only don't understand the risks of what they're getting into; they lack the language (and analogies) to describe the risks.
Re:Technical debt as an opportunity to accumulate technical ... by shoo on Monday August 15, 2016 @05:40PM (#12293695)
i think trying to explain in the language of options isn't a great comparison, perhaps a clearer way to think about it might be in terms of "robustness" to possible future scenarios (see also Taleb's Antifragile)
Re:Technical debt as an opportunity to accumulate technical ... by eximius on Monday August 15, 2016 @06:58PM (#12294157)
I think it is more accurate but less useful.
Re:Technical debt as an opportunity to accumulate technical ... by mscottford on Monday August 15, 2016 @06:10PM (#12293877)
There are many different ways to describe this problem, and it's very possible that using a call option as a metaphor is a better fit. Unfortunately, "technical debt" is the term that's currently in fashion, so you at least have to mention it when you're suggesting an alternative approach.

Incidentally, we're big fans of Martin Cronje's article[1] which suggests that "technical debt" is a broken metaphor, and he suggests using "depreciating assets" as an alternative.

[1]: http://www.martincronje.com/technical-debt-is-broken/

Re:Technical debt as an opportunity to accumulate technical ... by 0xmohit on Monday August 15, 2016 @07:39PM (#12294408)
> and he suggests using "depreciating assets" as an alternative.

Interesting.

Maybe, the alternative should be "depreciating assets" + "appreciating liabilities".

Re:Technical debt as an opportunity to accumulate technical ... by perseusprime11 on Tuesday August 16, 2016 @08:09AM (#12296862)
We already use depreciation in software when we start writing off capital allocation over time. This new metaphor maybe more confusing. I would rather stick with technical debt and give more context.
Re:Technical debt as an opportunity to accumulate technical ... by mathattack on Monday August 15, 2016 @04:43PM (#12293270)
I think you're right - it is very much like writing call options. It is still a liability, but of an unknown quantity.
Re:Technical debt as an opportunity to accumulate technical ... by mikekchar on Monday August 15, 2016 @08:04PM (#12294534)
There is a problem with these metaphors: activities that work against technical debt are often dependent on the skill and experience of the programmers involved. You often get no long term benefit from doing them.

I write code in a specific fashion, which involves a lot of TDD and a lot of refactoring. I've been doing it a long time and have refined it to the point where I expect to get payback in less than 1 week. But it is naive to expect that someone else will use the same techniques and achieve the same benefits right away (I have been, very, very naive in this respect at times :-( ).

For example, non-mocking TDD forces a particular set of design decision to be made up front. It also forces the creation of specific API entry points. Mocking TDD allows you to defer design decisions and makes it cheap to explore large design spaces. It forces you concentrate on your interfaces. The choice of which to use in various situations dramatically affects how well you can refactor. With non-mocking unit tests, you can get buried in the details of setting up contexts. With mocking unit tests, you tests can become very brittle. It also allows/encourages you to make some pretty horrifying design choices.

Even when people do TDD and have lots of tests, they often make poor choices and end up with code that they can't (or don't want to) refactor. The thing that people often do not understand is that unit tests and/or TDD will usually not provide much of a payback (in terms of productivity) alone. It is the refactoring that leads to simple design, reduces complexity, reduces code duplication, makes it easy to reason about changes, etc. Unit tests (and TDD in general) simply give you a framework for making refactoring easier.

The problem, from my perspective, is not about judging risk of upfront payback versus long term payback. When done well, the activities around reducing technical debt pay off so quickly and so dramatically that there are almost no cases where they are inappropriate. The problem is that using the techniques poorly often leads to no payback at all! In fact, sometimes you inherit a project with a rat's nest of crazy tests and the first thing you do to improve your productivity is delete the tests -- on the principle that less code means less complexity that you need to deal with.

Although my own personal style involves TDD and refactoring, I believe that the same can be said for other styles of development that are geared toward reducing technical debt. In my career I've done BDUP (1000 page requirement and design docs FTW!), I've done rapid prototyping (build 20 to throw away!), and a few other techniques. They can all work, but IMHO require even more skill to do well.

This is one of the things I wish someone told me at the beginning of my career. At the moment my current feeling is that there are virtually no cases where tolerating/embracing technical debt will lead to even short term gains. However, the alternative is not straight forward. Young teams must expend considerable effort finding expertise to help guide them forward. More importantly, everybody on the team needs to be aligned to the style that will be used. How you achieve that alignment is yet another can of worms.

Re:Technical debt as an opportunity to accumulate technical ... by shoo on Monday August 15, 2016 @05:36PM (#12293666)
maybe "unhedged" here is the important bit.

accumulated technical debt makes the software project less robust / less able to respond effectively to future events.

there are many examples in life where failing to do maintenance / prepare for contingencies is a clear short/med-term win, provided something unexpected does not occur.

Re:Technical debt as an opportunity to accumulate technical ... by rhizome on Monday August 15, 2016 @05:07PM (#12293456)
Is there a concept like YAGNI at all in stocks/finance?
Re:Technical debt as an opportunity to accumulate technical ... by dwaltrip on Monday August 15, 2016 @05:42PM (#12293706)
Buying stock in a company that is doomed to fail and end up with share price of $0.

Saying "YAGNI" and not implementing the foobar component would be like choosing to not buy the stock.

Re:Technical debt as an opportunity to accumulate technical ... by tim333 on Monday August 15, 2016 @08:20PM (#12294602)
Minimise capex perhaps.