What's That Noise?! [Ian Kallen's Weblog]

« MySQL vs. PostgreSQL... | Main | The Solar Decade »

20081208 Monday December 08, 2008

Good Bye, Perl

The other day, I was patching some Perl code. There I was, in the zone, code streaming off of my finger tips. But wait, I was writing Python in the middle of a Perl subroutine. Um. I found the bare word and missing semi-colon errors invoking perl -cw dingleberry.pl amusing. How did that happen?

Truth is, I find myself rarely using Perl anymore. I spent years building applications with Perl. Having made extensive use of mod_perl APIs and various CPAN modules, studied the Talmudic wisdom of Damian Conway, struggled with the double-edged sword of TMTOWTDI and rolled my eyes at the Perl haters for their failure to appreciate the strange poetry that is Perl it'd seem like a safe bet that Perl would remain on my top shelf. A lot of the complaints of Perl haters seem superficial ("ewe, all of those punctuation characters", shaddup). Yet, Perl has been long in the tooth, for a long time. I recall 5 years ago thinking that Perl 6 wasn't too far away (after all, O'Reilly published Perl 6 Essentials in June 2003). I'm sorry, my dear Perl friends, insistence that Perl is Alive rings hollow, now.

I still find it heartening to hear of people doing cool things with Perl. David McLaughlin's uplifting How I learnt to love Perl, waxing on about Moose and other "modern" Perl frameworks (but come on dude, everyone knows that PHP, sucks, heh). Brad Fitzpatrick released Perl for Google App Engine today. But Perl, I'm sorry. It's just too little, too late.

I'm just weary of the difficulties achieving team adherence to disciplined coding practices (or even appreciate why they're especially necessary in the TMTOWTDI world of Perl). The reliance on Wizardry is high with Perl; the path from novice to master requires grasping a wide range of arcana. Is it too much to ask for less magic in favor of easier developer ramp up? Perl's flexibility and expressiveness, it's high virtues, also comprises the generous reel of rope that programmers routinely hang themselves with. On top of idiomatic obscurities are the traps people fall into with dynamic typing and errors that only make themselves evident at runtime. Good testing practices are usually the anecdote to the woes of dynamic typing and and yet writing a good test harness for a Perl project is often a lot of work compared to the amount of work required to write the application code.

I well understand the security that programmers feel using static typing but I'm not saying the static typing is the cure to any ills. The compiler is the most basic test that your code can be understood and it gives your IDE a lotta help. That's great but static typing is also an anchor dragging on your time. From what I can tell, Java is the new C/C++ and Jython, JRuby. Groovy and friends (Scala, Clojure, etc) are the ways that people program the JVM with higher productivity. I'm not saying fornever to Perl (that's a long time). But I am saying Hasta La Vista, for now. I've been quite productive lately with Python (I know Perl friends, heresy!) and plan on pushing ahead with that, as well as with Java and other JVM languages. And where necessary, using Thrift to enable the pieces to work together. Python is certainly not perfect, it's quirks are many, too. But I've seen recent success with collaborative software development with Python that would have been difficult to accomplish with Perl. I'm not trying to stoke any language war at all, I'm just reflecting on how I've drifted from Perl. Amongst people I know and things I've read elsewhere, I'm not the only one. Don't fret, Perl, I'm sure I'll see you around.

       

( Dec 08 2008, 12:01:24 AM PST ) Permalink
Comments [7]

Comments:

Ian, it's great to see you blogging and twittering more lately. You're an excellent writer. Interesting stuff. I enjoyed doing Python with you. Dave

Posted by Dave Briccetti on December 08, 2008 at 04:10 AM PST #

Why was writing a good test harness so difficult? I'm genuinely confused.

Posted by chromatic on December 08, 2008 at 04:10 AM PST #

I for one wouldn't mind a deeper discussion from you on the success with collaborative software development you've seen with python over perl. I know I'm risking another shadup here, but isn't the profligate punctuation in perl code a maintainability challenge? If we can agree on that, then it is a material language choice factor. If not, I'll take my serving of shadup now, thank you.

Posted by JosefA on December 08, 2008 at 04:10 AM PST #

That's saying good bye with a lot of respect ! After all the countless articles about Perl being dead mostly written by PHP programmers, here is at least a much more sophisticated view towards the issue. For me, Perl is still an essential programming language that I wouldn't want to miss, especially for developping web applications. And I am sure there is still a large community of people who are and will be using Perl now and in the future.

Posted by Ingo Steinke / Active-Webshop on December 08, 2008 at 04:10 AM PST #

Ultimately every programming language sucks. But compared to other programming languages, certain languages are a lot better than others. For me the main language since 5 years is ruby, and although I have a very good idea of what things I would want to see differently in a possible "better" language, no other language comes even close to ruby in this regard for several reason. The closest competitor would be python, and I think both languages are elegant, but the mindset of python really is totally different and probably the biggest difference therein. On the other hand I clearly see a huge need for C (!) in both python and ruby, which has amazed me because I think C needs to go away as well. (But doing away with C is impossible so we will have it another 200000 years. It is just interesting that C lead to C++ which in return lead to Java C# D ... ) A modern language needs to be developed continually as well, it needs to keep visions alive. I think PHP still has its vision going on (the www world) and will survive as long as people use it and drive it into the www aspect. But I am not sure where perl is going exactly. Maybe Larry abandoned it? PS: What I would also like to see is an elegant SCRIPTING language that is like a simplified Haskell with nicer syntax. Like a python-haskell-lisp language (but please no ((()))))

Posted by markus on December 08, 2008 at 08:32 AM PST #

Why you didn't used static typing in Perl? It available in language for objects and for basic types by module in CPAN. White box testing is easier in Perl, I recently had found a bug location using sub substitution. And it wouldn't be caught by static typing. Perl programming is much easier with tests, but is also much easier for other languages, but not all languages has such good testing libraries. IMHO you can write bad code in every language, it is just Perl's feature that badly written code is more evident. And in Python you would need to do manually to provide readbility that in Perl would be achieved by running perltidy.

Posted by Alexandr Ciornii on December 08, 2008 at 05:24 PM PST #

"I've seen recent success with collaborative software development with Python that would have been difficult to accomplish with Perl." Then you're doing it wrong ;) Seriously. If you find something else easier after switching from something you've been doing a long time, then you probably weren't doing it right or had some personal issues with it. I've seen previous and recent success with colaborative software development with perl (that would have been difficult to accomplish with python). That's working both onsite and with globally distributed teams. Both commercial and open source projects. You have to wonder reading this blog post if there is some secret python club you're not allowed to join until you've recanted and proclaimed that Python is better than Perl and you've seen the light.... Always the same cannards, always the subjective, nobody ever just seems to do some work with python and STFU and get on with it. A couple of old proverbs come to mind : Beware the zeal of the convert, and "the grass is greener". A.

Posted by Aaron Trevena on December 11, 2008 at 03:52 AM PST #

Post a Comment:

Comments are closed for this entry.