London Perl Workshop 2011

This year’s London Perl Workshop continued its well established trend of excellent and increasing quality.

After Mark Keating’s opening address, I went to Dave Cross’s Modern Core Perl talk. Having not paid enough attention to the description (or the title), I was expecting this to be about the fancy new frameworks that have become all the rage since my new Perl developments have been mostly sidelined. While that would have been useful, it was actually about the fancy new features in Perl itself which were added in versions 5.10 and up. I’m currently stuck using 5.8 at work, and while I don’t care so much about smart matching, stacked file tests, or some of the other new features, I’m now particularly envious of everyone who can use defined-or, state variables, named regex captures, non-destructive substitution and aggregates which take reference arguments. I’m now wondering how I can manage to upgrade Perl at work without it breaking everything or taking any time away from what I’m actually supposed to be doing.

In the morning break, free drinks and cupcakes were available, thanks to Exonetric. This type of sponsorship was a pleasant surprise to see for the first time last year, and it shows how well the workshop is doing to see it continue. The cupcakes looked and tasted great, but a few people were put off by the ridiculously excessive decoration. I’m quite happy to eat a cake which is dwarfed by its icing, but I did misjudge the carbohydrate content, and my extra insulin dose wasn’t nearly enough to keep my blood sugar down to a sane level.

After the break, I went to Stevan Little’s A Brave New World, which showed off a new way of doing OO in Perl 5. It doesn’t go quite as far as Perl 6, but aims to provide a flexible and extensible MOP which could eventually serve as the basis for Moose and other object system extensions. Hash based objects have served us well for the last several years, but leave the unwitting open to all kinds of mischief and misuse. Stevan’s work is currently an extension module (available on Github), but could one day be implemented in core for extra efficiency.

Tatsuhiko Miyagawa’s Plack tutorial started at the same time as Stevan’s talk, so I couldn’t go to that, but Leo Lapworth’s Plack Basics talk was a good alternative. I’ve been to Plack introductions before, but this was the first one which showed how universally useful and straightforward it is. This is something I might actually be able to sneak in at work, where being able to more easily test our rag-tag band of CGI scripts would be very much appreciated. It might still be too late though, as they’re all likely to be replaced with Java or Groovy before too long.

Then it was time for lunch, which for the first time was sponsored (though I don’t remember who by). This was one of the biggest improvements for this year’s workshop, as it meant that almost the entire body of attendance was in the same venue for lunch, rather than being scattered across a bunch of different cafes and pubs. I even managed to overcome my social awkwardness, and get somewhat involved in some interesting discussion about the p5-mop development.

Back to the workshop, and Claes Jakobsson’s Don’t Debug Now, Debug Later talk. He presented Runops::Recorder, a fascinating module which uses a custom runops loop which records events about the execution of perl programs. This comes with a tool which allows you to effectively step through the execution of code which has already run, allowing a glimpse into what makes it go wrong. This is presented in much the same way as a source debugger, showing the script being executed with the current line highlighted. The types of event which are recorded are still in flux, and this looks like it’s going to be a very useful tool for forensic examination, especially with the scope to write custom event replayers.

Neil Bowers talk, CPAN Curation, presented a possible solution to a common problem, that of finding an appropriate CPAN module. Perl’s TIMTOWDI motto is taken to extremes in a lot of cases, and it’s possible to find tens of possible candidate modules to address many development problems, without a reliable way of deciding which if any of them are best suited, or even suited at all. Neil’s answer is to write a comparative review of all of the candidates, so that other users aren’t faced with the same impossible choice. These reviews are currently on his blog, but a more suitable home is being investigated, and it sounded like he’d appreciate help from others in his enormous endeavour.

Next up was Carl Mäsak’s Small Languages, Less Accidentally. He was trying to convince us that while domain specific languages are very useful and easy to implement, they’re also easy to do badly. Perl 5’s regexen are often used for parsing, but Perl 6’s grammars offer a much better solution, and can already be used in Perl 5 with modules like v6. Grammars are actually classes, can participate in inheritance, and are much easier to unit test than incomprehansible monolithic regular expressions. I don’t feel like I’ve given a good explanation of this talk, but I did miss the first couple of minutes due to Neil’s talk overrunning.

Matt S Trout’s talks are always entertaining and enlightening, but First, Tak Wrote The World didn’t reach quite the mind twisting levels of some of his previous presentations. Tak is a tool for running jobs on multiple hosts over ssh, without requiring anything but perl to be installed on the remote ends. Matt’s system does all kinds of clever things to allow arbitrary commands and Perl code to be executed on the remote servers. If you can live with the performance hit, it also provides an equivalent of Java’s Remote Method Invocation. It’s all very impressive, but I can’t help thinking that it’s a bit heavyweight for one-offs, and doesn’t seem like the right approach for long-term production services.

The penultimate session of the day was the lightning talks; several speakers each with a 5 minute time limit:

  • Dave Cross – A Modest Proposal
    A rather tongue-in-cheek suggestion that marketing to increase the number of Perl programmers would just increase the number of bad Perl programmers. The obvious alternative solution is to restructure Perl Mongers and Perl Monks as Perl Masons, drive the language underground, and distribute all code with Acme::Bleach.
  • Steffen Müller – Class::XSAccessor
    From one of the workshop’s sponsors, Booking.com, this is a module which makes hash-based objects more efficient.
  • Jon Allen – App::cPackage
    A handy tool for creating self-contained install packages for Perl modules. These can then be run on any system with perl already installed, even if they’re disconnected from the internet.
  • Tim Bunce – Dist::Surveyor
    Another new module, which can be used to figure out which versions of which CPAN modules are actually installed in a library directory. This gives you a simple way to install the same set on a new system, or a new version of perl, by creating a MiniCPAN from the resulting list. The added bonus being that all of the modules are re-tested in combination with each other as a by product of the reinstallation.
  • Gabor Szabo – How to get your job done and remain sane
    Some businesses don’t appreciate the value of all best practices (“If you need version control, you’re not good enough”, “I don’t believe in unit testing”), but Gabor had a few suggestions for keeping your head in the face of such adversity. If you’re lucky, you can even change the culture from the inside.
  • Tatsuhiko Miyagawa – cpanfile
    A tool inspired by Ruby’s gemfile, this is a DSL for specifying the dependencies of applications, without necessarily having to create a CPAN distribution, or install the code locally (useful if you’re deploying in the cloud). This will be supported by the next versions of cpanminus and carton.
  • Torsten Raudssus – DuckDuckGo
    A new search engine focussed on privacy and utility. DuckDuckGo doesn’t bubble track its users, or even log IP addresses or timestamps finer than hours. It’s written in Perl, and provides an API for extensions. It does get its raw results from Bing!, but filters out the spam.
  • David Leadbeater – Uniqueness
    A new URL shortener specifically for git repositories, gi.tl takes advantage of the well-engineered uniqueness of git commit Ids
  • Mike Whitaker – Stop scratching!
    If you have an itch, don’t fall into the NIH trap when trying to scratch it. Have a look at the Task::Kensho meta-distributions before trying to write it yourself.
  • Andrew Main – It’s the optree that matters
    Another tongue-in-cheek talk, aimed at reducing the flame wars which regularly erupt over coding style. How you arrange your code, where you put your braces, and whether you use statement modifiers all have very little effect on the optree produced by compiling your code. perl’s B and O modules don’t quite support it in recent versions, but we should be able to store the optree in our revision control systems, and generate our own preferred formatting of the source code for editing.
  • Tim Dobson – BigV
    Another sponsor of the workshop, ByteMark. This is their new scalable hosting service, “proudly build for worst established practice.” By which they mean you can start quick and dirty, but don’t have to stay that way.
  • Mark Blackman – XML::Compile::SOAP
    This module takes WSDL as input, and gives you a simple hashref-to-hashref API for calling the described service.
  • Matt S Trout – The source of all evil
    Filter::Keyword is a new way of doing what Devel::Declare did; allow new keywords to be added to Perl. But this one does it in pure Perl!

Back down to the pub for the final session; free food and drink paid for by the sponsors. This size of this year’s spread was much better estimated than last time, with only a few sandwiches lasting more than half way through the evening. The weather was also much more clement, allowing attendees to talk outside where they could actually hear what they were saying. Lots of interesting discussion was sparked from the workshop’s presentations, making this one of the most useful parts of the day.

The London Perl Workshop is an extremely high quality conference, and it doesn’t cost a thing to attend! Many thanks to the organisers, sponsors, presenters and volunteers. I’m definitely going next year, and I recommend that you do the same if you have even the slightest interest in Perl.

Advertisements
This entry was posted in lpw, perl. Bookmark the permalink.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s