|
YAGNI (You Ain't Gonna Need It, or, for all the grammar nazis in the audience: You Aren't Going to Need It) is one of the best, and most pessimistic, software development guidelines.
When considering a new software feature, YAGNI tells us to ask ourselves if we really, really, really need it right now.
It takes but a flash of brilliance to think up a new feature, but hours or days or months of actual hard work to realize it. We need to prioritize what we're going to do and when we're going to do it.
YAGNI is meant to help us prioritize. It helps us cull features by asking if we're really going to need them. Why waste time adding page caching to your webapp, when dynamic generation is Fast Enough For Now (too bad FEFN isn't as compelling an acronym as YAGNI or I could be famous). That time spent on page caching could be better spent on something that's meaningful to your users. Besides, what if your webapp is a failure? What if you never need page caching?
The thought that you're really cool feature idea might be a complete waste of time takes some of the wind out of your sails, doesn't it? I know it does mine. Now imagine that you apply YAGNI to every aspiring new feature? Yeah, sort of depressing. Especially if you're already out on a limb developing something that, you worry, people might not care for.
In Othello, there's the concept of something called a waiting move. The idea is that you've identified the best possible move you could make. It might even be a killer move. But you don't take it just yet. Instead you take a move that has no great effect on the board. By opting for the waiting move, you can save your killer move for later. You're no longer deciding what to do, you're deciding when to do it.
Sure, while you're waiting something better might come along. You might not play your killer move at all, but you never stop believing that it would have been a great move.
I actually think YAGNI and Othello's waiting moves embody the same concept. Both are brilliant, winning strategies. Yet, there's a certain emotional side to YAGNI and software development. We tend to get attached to our good ideas. It can be hard to question their true worth. And, it can be especially hard to set them aside.
Even when it's the right thing to do.
|
Nicolás Sanguinetti says,