Are Lines of Code really a measure of either success, productivity or popularity?

October 30, 2006 - by jason

Via this and that, I found myself reading PHP Eats Rails for Breakfast

The title PHP Eats Rails for Breakfast and subtitle Despite the buzz around sexy new frameworks like Rails and Django, PHP is more dominant than ever initially commits the same fallacy that others have and that is to compare frameworks (Rails and Django) with programming languages. And then the suggestion becomes that one can interchangeably use Rails and Ruby, Django and Python.

New projects in their analyses were open source projects. And despite the popularity and open source availability of Rails and Django, they’re both relatively young and I can’t think of many open source and substantial applications written in both (all of our’s for example are closed source).

But the telling graph there is actually the last: more than 15% of “New Projects” are being written in Ruby. This counts “projects” not “net” lines of code.

Correct me if I’m wrong, but if 20 PHP projects do what most PHP projects have done and that is build out a custom “framework” that’s splayed out in /lib/ and /include/ directories, then they’re naturally going to have much more code than 20 Rails projects that are all taking advantage of the ~75,000 LOCs that’s present in the Rails framework.

What’s gets counted in a valid comparison then?

Would a 5000 LOC Rails application be equivalent to an 80,000 LOC PHP (non-framework using) application?

Do we get picky and only count the part of Rails or Django that actually gets “used”?

So when we have an application like Beast (svn, example forum) that implements a forum in about 500 lines of code.

How do we compare that to feature-comparable application in another language?

Rails is also a bit unique is that most people you see around only started coding in Ruby because of the Rails framework, and there aren’t many other examples of a single framework being so dominant within a language’s community.

I simply think the basic finding that’s in the title is just there to get some notice. I don’t quite have Gruber’s Jackass Stamp but if I did … someone might get stamped.

So what do you think?

Are they simply full of schnitzel or am I missing something?

Then in an Age of (Web) Frameworks, is there a relationship between LOCs and success, productivity or popularity?

How do frameworks impact typical metrics used by managers?

And it’s funny because we’ve had the same conversation internally where I’ll watch commits go by and then email someone and ask, “Is that feature really just 9 lines in our app?”

:

Sign up now for Instant Cloud Access Get Started