September 2007 Archives

YAPC website gets an overhaul

| No Comments

Looks like Jim Brandt had some free time once the mod_perl 2 User's Guide was published. Now he's overhauled the YAPC website at Jim says "it was in desperate need of some TLC. I drew some momentum from YAPC::NA this summer and finally gave it a facelift." The calendar is based on brian d foy's Google Calendar of Perl events.

For extra fun, see how many Perl people you can identify in the photo on the front page.

Twitter and Facebook applications for CPAN launched

| No Comments

Do you Twitter? Are you, like approximately 10 bajillion people worldwide, on Facebook? I'm on both -- and probably about fifty more social networks besides. And I have to say, until now most of them have been missing a vital -- vital, I tell you -- feature: CPAN notifications.

Well, Randy Ray and Leon Brocard to the rescue! The two of them have independently released CPAN notification tools for Twitter and Facebook respectively.


Randy Ray's created a Twitter bot called cpan_linked (as opposed to an older, defunct "cpan" bot), which you can follow and have it notify you of new CPAN releases. Randy wrote about it on

The bot polls the RDF URL every 15min or so, using an If-Modified-Since header. Any new CPAN uploads are queued up for posting to Twitter, spaced out evenly over the 15min waiting period (i.e., if there are two new CPAN uploads then tweet fires immediately and the second waits roughly 7.5 minutes to fire... fifteen new uploads would fire at roughly one-minute intervals) so that it doesn't suddenly spam your Twitter client.

Me, I already read that feed via RSS (for the benefit of CPAN Watch), but if you like your notifications via Twitter then Randy's bot could be just the thing.


Meanwhile, Leon Brocard has released a Facebook app for CPAN notifications, thus letting me take that idea off my own to-do list. The app's called CPAN Friends, and you can install it by clicking on that link (assuming you're a Facebook member already).

CPAN Friends will notify your friends (or rather, any of them who also have CPAN Friends installed) whenever you upload a new release to CPAN. It requires you to enter your PAUSE username and password. In this case I trust Leon not to mis-use them, but it's yet another place where something like OAuth would be great.

Anyway, you can read more about the Facebook app on Leon's journal.

Go check out these apps and let us -- and the authors -- know what you think!

Russian Perl Workshop on October 26, 2007 in Moscow

| No Comments
The Russian Perl Workshop 2007, "Perl Today", will be held in Moscow on October 26, 2007. The specific location hasn't been decided yet, but the program is taking shape. It's a no-cost hands-on teaching workshop for up to 100 participants on three topics: Perl 6, Perl and XSLT and Perl for beginners. The workshop will be held as part of InfoCom 2007.

Perl Foundation elects new chairman, president and vice-president

| No Comments
The Perl Foundation announced today that they new positions have been elected in the Board of Directors. Bill Odom, previously President, becomes Chairman; Richard Dice becomes President; and Jim Brandt becomes Vice President. Kevin Lenzo who has for so long served the Foundation leaves his Chairman position and becomes Director Emeritus.

Perl Training Australia provides tips by mail and Atom

| No Comments
Perl Training Australia is now providing tips in Perl either by an announcement mailing list or Atom syndication. Recent tips have included "Memoizing", "Benchmarking basics" and "Searching for items in a large list". They're definitely worth reading. The tips home page is at

Perl::Critic: an interview with Chris Dolan

| No Comments

Chris Dolan recently received a Perl Foundation Grant to write 20 new policy modules for Perl::Critic. I managed to catch up with Chris by email and ask him a bunch of questions about his work on Perl::Critic, the TPF grant, and more.

Kirrily: So, how did you first get involved in Perl::Critic?

Chris: Funny, I had to look back at my email to remember this. You'd think I could remember two years ago...

I read Damian Conway's Perl Best Practices (aka PBP) in summer 2005 and thought, "Finally! The solution to the 'Perl is not readable' myth!" I tried applying all of the ideas manually in a new module I was just about to release to CPAN (Net::IP::Match::Regexp). I found the process rewarding, but a little tedious and error-prone.

After working with the PBP recommendations manually, I thought about writing some code to judge some of the recommendations automatically, but happily I decided to check CPAN first. I found Perl::Metric::Basic and posted some RT reports. Then I found Perl::Critic, which had just been renamed from Perl::Review. I found the code much more approachable that Perl::Metric and soon filed a few RT reports and a cpanratings review. Jeff Thalhammer, the P::C creator and leader, emailed me back personally thanking me for the feedback. After that, we had about a dozen back-and-forths where Jeff sent me pre-release tarballs of Perl::Critic and Test::Perl::Critic to test before sending them to CPAN. Then, I wrote my first from-scratch policy (Modules::RequireEndWithOne) about a month later, and I was hooked.

Kirrily: What prompted you to apply for a TPF grant? How did you convince them to give you money? How did you find the grant process?

Chris: I hope nobody criticizes me for admitting this, but my reason for applying for the grant was self-motivation. Our second child was born Jan 1, 2007 and the company where I worked was struggling, so it was a hard time to find energy for my open source efforts. I usually work best under pressure, so I decided the publicity of a TPF grant would force me to get something done (and the money will be a nice bonus too).

I wrote a ton of grant proposals in my former life as an astronomer and, of course, tons of business proposals as a web/programming consultant, so I found the TPF grant process pretty easy. The positive impact of Perl::Critic is obvious on the community of people who care about good Perl code, so the justification part was straightforward. The harder part was deciding what part of P::C to propose to build.

Kirrily: Is there a theme or themes to the 20 modules you're doing?

Chris: Yep. We keep an extensive TODO.pod file in the P::C svn repository. One portion of that file is devoted to PBP recommendations that seemed feasible to implement in code. I had created that list over a year earlier by paging through the PBP book and brainstorming implementations for each recommendation. Needless to say, some of the PBP recommendations will never make it into P::C -- for example "Never assume warning-free compilation implies correctness" (page 432).

It turned out there were an even 20 PBP-based ideas in the TODO list (vs. about 40 non-PBP ideas). Twenty seemed like a nice round number and a challenging-but-doable quantity. At that time, I was primary author of 27 of the 93 finished policies, so I had a pretty good idea of what was involved.

Kirrily: Why should people use Perl Critic? Why shouldn't they?

Chris: In my opinion, it's good for two things:

1) Finding bugs (real bugs and potential bugs)

2) Making your code more approachable

Both are especially important for open source code that might be used by thousands of other programmers. Why write bad open source code?

One reason not to use Perl::Critic is to put a badge of honor on your code. Achieving P::C compliance is a good thing to announce to the world because it tells users that you care about the quality and consistency of your code. But P::C doesn't help make your code better directly. It just tells you that your code isn't broken in one of about 100+ known ways. And some of those 100+ contradict each other! Compare that to the innumerable ways to write bad code. So, you've got to start with good code and use P::C as a tool to make it a little better.

One piece of advice I like to share is that you should not be afraid to turn off P::C policies that don't work for your code. I think Damian gave similar advice in PBP. In the P::C code itself, we have 98 instances of ## no critic(...) which turns off certain policies. Even Perl::Critic is not 100% Perl::Critic compliant! But 98 out of 27,000 lines of code isn't bad.

Another controversial topic is whether .t files should be P::C compliant. Personally, I don't bother. Writing test code needs to be fast and easy or it falls by the wayside.

Kirrily: Do you know of any really interesting uses of P::C out there? Famous companies using it?

Chris: Good question. We should ask Jeff Thalhammer about that -- as P::C founder, he has a closer connection to our user community. There was brief talk about creating a for-profit consulting entity to help big companies write better code using P::C, but I don't think anything came of that (I was too busy to participate).

What I find interesting is the people/groups/companies who have privately implemented their own policies for P::C. Parrot, for example, had a few custom policies the last time I looked. Another example is MathWorks, who funded the Perl::Critic developers to write some specific policies they desired. Now that's a business model any open source developer craves!

Kirrily: What next after you've implemented these P::C modules?

Hmm, I have no real plans. More policies, I guess. I'd love to get more people writing them. They aren't too hard to create and without them P::C is worthless. If anyone wants to get involved, I'd be happy to be a mentor. Giving fish vs. teaching fishing, y'know.

In my day job, I do a lot of Java coding (and often enjoy it). We use a commercial package called CodePro by Instantiations which is conceptually similar to Perl::Critic but is much more polished. They have over 900 policies to choose from, many of them specifically designed to squelch anti-patterns in the big APIs like Spring, Hibernate, Struts, etc. Jealously, I've often thought that they have an easier job than we do because Java is so much easier to parse than Perl, and the code smells seem to fall in more easily identifiable patterns.

When Perl 6 becomes popular, I'd like to see Perl::Critic be implemented against it. Perl 6 will have a grammar that is much more amenable to grepping. Behind the scenes, I'd like to see the Perl 6 version of P::C work against de-sugared syntax or perhaps even the abstract syntax tree to simplify the policy writing. Unless a huge amount of work goes into improving PPI, that's not going to happen for Perl 5. At one point, we talked about writing P::C policies using an XPath-like notation, but nobody ever championed that goal. I discovered that FindBugs (another Java code analysis tool) took that approach successfully. Maybe P::C can benefit from the Parrot tree grammar engine (TGE). Or the optimizer. After all, the syntax pattern matching that P::C has to do is not that different from the opcode pattern matching that an optimizer performs.

Overall, what I'd really love is for Perl 6 to avoid the "write-only language" moniker that got slapped on Perl 4 and Perl 5. If P::C can help with that, then it has succeeded.

Thanks, Chris!

Find out more about Perl::Critic at or listen to this PerlCast interview with Jeff Thalhammer, creator of Perl::Critic.

Countdown to Pittsburgh Perl Workshop: Schedule released

| No Comments

One month to go, and the schedule for the Pittsburgh Perl Workshop has been released, and it looks like a great lineup.

Wish I could be there! But I'll be there in spirit, at least; Michael Schwern will be presenting the results of the Perl Survey at PPW.

Perl's alive and kicking in the job market

| No Comments

renodino writes in his journal that he's sick of hearing FUD about how Perl is dead. So, he built a quick graph of job ads on

His graph shows Perl jobs as the blue bar, with the dark blue bar next to it being those jobs which specify Perl as well as any other dynamic language. It's pretty obvious that if you're looking for a job programming in a dynamic language, Perl is the way to go.

renodino writes that he's intending to update the graph regularly, so it will be interesting to see whether Perl can maintain its huge lead over time.

Site review: BookFinder

| 1 Comment

Want a copy of the Camel book for $4 including shipping? Trying to find a first edition of some obscure tome? has been finding books for a decade now, and it's all Perl.


I visited HQ in Berkeley, California a couple of weeks ago and met with Anirvan Chatterjee and Charlie Hsu, some of the brains behind the site. We talked about books, CPAN, test driven development, CPAN, books, and CPAN.

The guys have been using Perl and Mason web framework since the beginning, but they've more recently become fans of Perl's test modules, such as Test::More. Anirvan tells me they have 33,000 tests spread across 85 test files. "It's really been making refactoring a whole lot easier." He admits, though, that he's not thinking in tests yet for some of their database workflows. Luckily most of the code on CPAN has tests. "It's part of the culture -- to see the tests, they're just there. There's always something you can look at and say, 'oh, that's how they did it.'"

Other favourite Perl modules? The guys listed:

  • List::MoreUtils -- "They're tiny, but they save me five lines of code, each one," says Charlie
  • Geography::Countries and Geo::Distance, which uses to figure out shipping rates around the world.
  • Locale::Maketext for i18n. "We're localised for 4 or 5 different locales right now, and it's been really fun and challenging. We had to take this huge codebase and make every little bit of it localised, and L::M made it work for us."

Anirvan also described Perl::Critic and Perl::Tidy as "life-changing". They've contributed some patches back to Perl::Critic to help it run on Perl 5.6, as well as contributing patches to other open source projects, such as SpamAssassin.

So far, however,'s involvement in the Perl community has mostly been online. Anirvan admitted, "The concept of the Perl community never really came alive for me until recently, when I started listening to Perlcast. I realised, hey, there are really people out there, talking about Perl. Just listening to Perlcast has made me think that I need to get to YAPC one of these years." So hopefully you'll be seeing the guys at an upcoming Perl conference or two.

As it happens are hiring. I asked them for their pitch. "We're a developer driven company -- all Perl nerds here. And we're committed to using the powers of Perl to make sense of really, really dirty data. You can affect the direction of the company. Only two other people here! We're stable, because we're owned by a larger company but we operate as a totally independent unit. So we have health benefits and all that." You can read their job ad on

CPAN search adds author pictures


This just in from Michael Schwern:

In order to improve recognition of CPAN authors and help users to empathize a bit more with them before they send off a scathing "OMG YOUR MODULE IS GARBAGE I HATE YOU!!!" bug report, now includes pictures of the CPAN authors. Now you can see Graham Barr's grinning mug or RJBS's shining brain dome or Michael Schwern's secret Lorikeet overlord.

The images are drawn from A Gravatar is a Globally Recognized Avatar. It's pictures associated with an email address. You get the picture for an email by constructing a simple URL to talk to Gravatar::URL does this for you. is simply getting the Gravatar associated with an author's address. If you're a CPAN author, just sign up with using your address and upload a picture.

The Gravatars are cached by Search so if you add your own give it a day or so to catch up.

mod_perl 2 User's Guide published: An interview with co-author Jim Brandt

| 1 Comment

mod_perl2 User's Guide ( by Stas Bekman and Jim Brandt has just been published by Onyx Neon, and Amazon says it's shipping. I can't think of the last time I've been as excited to see a Perl book get published. Besides brian d foy's Mastering Perl, there hasn't been a significant Perl book in quite a while. Perlbuzz is going to work with Onyx Neon to have a book giveaway, so watch this space in the next few days.

Jim Brandt took some time to talk with me about the book, why you need to switch to mod_perl 2, and why it took so long to get the book to market.

ctags 5.7 improves Perl support

| No Comments

Exuberant ctags, the standard tags utility on most systems today, has released version 5.7 for download with the following improvements to its Perl support (among many other improvements):

  • Added support for 'package' keyword
  • Added support for multi-line subroutine, package, and constant definitions
  • Added support for optional subroutine declarations
  • Added support for formats
  • Ignore comments mixed into definitions and declarations
  • Fixed detecting labels with whitespace after label name
  • Fixed misidentification of fully qualified function calls as labels

If you've never used tags or ctags, start today. Your life will never be the same after.

For example, if you run ctags on a tree of source code, and then run vim -t some_function from the shell, vim will open the file where some_function lives and leave your cursor there. Alternatively, if you're editing a file with vim and you position your cursor over the word some_function and press Ctrl-], vim will jump to the function. Other editors have similar bindings.

Your editor doesn't know Perl, but it relies on ctags generating a tags file, which is in a standard file. Of course, ctags isn't perl itself, so isn't as exact. These improvements in v5.7 will make your tag files more accurate.

If you've got a Perl module, it's easy to add a makefile target for tags. See any of my major modules (WWW::Mechanize, ack, etc) and steal from the Makefile.PL, or just add the following to your Makefile.PL:

sub MY::postamble {
    my $postamble = <<'MAKE_FRAG';
.PHONY: tags

	ctags -f tags --recurse --totals \
		--exclude=blib \
		--exclude=.svn \
		--exclude='*~' \
		--languages=Perl --langmap=Perl:+.t \
(With ctags 5.7 it turns out, that --exclude=.svn is no longer necessary, as ctags automatically knows to ignore it now.)

Copenhagen to host YAPC::EU 2008: Official announcement

| 1 Comment

This just in from the folks at Copenhagen Perl Mongers:

The YAPC::Europe Foundation is pleased to announce that Copenhagen, Denmark has been chosen as the site for YAPC::Europe 2008, the ninth European YAPC.

Copenhagen faced stiff competition from Braga, Portugal, which hosted a memorable YAPC::Europe in 2005. This year also marked the first submission from a group unaffiliated with Perlmongers: the Informatics department of Wellcome Trust Sanger Institute in Cambridge, United Kingdom. We hope that both these groups will give us the opportunity to consider their proposals again in the future.

We are confident that's experienced team - which was responsible for several Nordic Perl Workshops - will put together a wonderful conference.

We hope to see you in Copenhagen next summer!

YAPC::EU -- the European "Yet Another Perl Conference", and Europe's top Perl conference -- runs annually in a different city each year.  If you missed this year's, in Vienna, you can read more about it on Perl Buzz in these related posts:

It's sysadmin week at the Perl Survey

| No Comments


One of the goals of The Perl Survey is to reach out to people who only use Perl occasionally, and might not think of themselves as Perl programmers or as members of the Perl community, and then to find out who they are and how they're using Perl.

During September, the Perl Survey will be focussing on a different group of non-core Perl users each week, and this week it's system administrators.

Perl has long been called "The Duct Tape of the Internet" and many call it "the sysadmin's best friend". If you use any kind of Unix, your system is probably held together by Perl in more ways than you know, from backup scripts to packaging systems to automating day-to-day tasks. But Perl's not just a Unix tool; the range of platforms it runs on, from Windows to the big iron, makes it a sysadmin's friend in all kinds of circumstances.

Many sysadmins write the odd Perl script. (Sometimes it looks like a shell script that grew tentacles, but it's still Perl.) But unless those sysadmins are hooked into the Perl scene, they'll probably never know about the Perl Survey. So, here's a call to action: if you know any sysadmins, whether at your place of employment or at your local drinking establishment, forward them a link to this article, and then ask them to take the Perl Survey.

BOFH coffee cup photo by ErikGjerde, used under CC-BY-NC license.

Final YAPC::Europe roundup

| 1 Comment

A final handful of YAPC::Europe stuff.  Looks like it was a great conference!

The winner of the Perl Buzz package in the charity auction, supporting the YAPC::Europe Foundation, was Greg McCarroll. Keep an eye out for an article and ad telling you about his favourite topic or cause. He hasn't told me yet what that is, so it's a mystery to all of us.

A number of people posted photos to flickr of a frankly terrifying dinner during the conference. This one's by Bob Walker:


More photos are available here and there. My favourite set are these photos at; they're really fantastic shots, so go check them out. I'd have included some inline here if there was a CC license. jonallen's photos are also worth a look, as are Matt Trout's. Matt's page includes links to blog posts about the conference and, inexplicably, a cookbook for dishes such as "Roast pork with apples cider vinegar and rosemary" and "spiced cheese savouries". Someone's going to have to explain to me how that connects to the conference.

A handful more talks were uploaded to Slideshare, including:

Elsewhere, I dug up these by Matt Trout:

Fair warning though: they're Takahashi style, so a bit tricky to understand without the accompanying speech.

And most importantly, video of the topless arm-wrestling match between domm and Damian Conway -- another item from the auction, I believe, or else YAPC::Europe is stranger than I thought -- has been posted to YouTube:

Speedlinking for September 4th


A handful of interesting articles via the journals today:

Frozen Perl 2008 will be February 16th, 2008

| 1 Comment
The Minneapolis Perl Mongers have announced the date of their one-day Perl workshop. Mark your calendars now for Frozen Perl 2008 February 16th, 2008.

Frozen Perl will be an all-day workshop held at the University of Minnesota. Pricing has not yet been announced, but I'm sure it will be under $100.

If, like me, you found it to be a bit too far to get to the Pittsburgh Perl Workshop on October 13-14, 2007, this is a great alternative. I hope to see you there.

« August 2007 | Main Index | Archives | October 2007 »