FOSDEM 2011 report

So this year I was to FOSDEM, and this was my first time. Wow. F*cking Wow!

FOSDEM hacker tools

This event is awesome. There are so many hackers out there it’s just impressive, like 6000 or something… And it is Belgium, which means pretty awesome beers everywhere for a few euros. But well, I’m not here to speak about beers, am I?

From my perspective though, what was awesome was not FOSDEM itself, but the fact that it was the first time that four of Dancer’s core-team developers met together, in real life. This was huge.

I was with Franck, Sawyer and Dams, and we processed *a lot* of stuff during FOSDEM. Sawyer already wrote a complete report of what we did saturday, and I think he’s going to publish soon a report for today’s achievements.

What really makes me happy is that we have a pretty good energy in the core-team, everyone is motivated like hell and I can’t even realize all we did in 24 hours: all known bugs fixed, 7 pull request processed, every issues are classified and tagged (with a new policy) and we managed to release 1.3003 this afternoon with all the changes applied during our hack sessions. Productive isn’t it!

Sawyer did a talk about Dancer in the perl devroom, it was… well, I think it was one of the best talk I’ve seen so far, and I’m not saying that because it was about Dancer. He’s a really good speaker and had a very interesting slideshow. Dams told me during the talk: « You know what’s the best feature of Dancer? It’s Sawyer! ». Totally!

The room was crowded (there wasn’t enough seats for everyone), people laughed a lot, and Dancer sounded to be so exciting I felt like rediscovering my very own project.

The feeling of seing such a great talk performed about something you’ve created is really weird and fullfilling.

At the end of the day I did my talk about “The art of growing a Perl project”, it went fine (although I’d have liked to be more fluent) and someone came to me at the end and told me: « You know what, I have this project I wasn’t sure to release for a while, after your talk, I clearly want to! There’s no reason I should keep it for myself.». So I think what I wanted to say did make its way to someone ;)

After the talk someone from the Bulgarian Perl workshop asked me if I could come for giving a talk at their event at the end of the month. I’ll have to see if I can manage to do it, but that’s sounds difficult at first glance.

Anyways, such a great weekend we had. FOSDEM++ Belgium++

What about some news?

It’s been a long time since I’ve wrote something here, so here it is for a quick review of the news.

PerlDancer has a new website, apparently it really looks to please people, and I’m very glad of that! Huge kudos go to Oxide who did all the artwork. His design is so cool, we all love it!

I’m going to attend FOSDEM and am very happy to do so. Lots of Dancer developers will be there and we’ll have plenty of time for working on the project (well, if we don’t stay too long in the awesome pubs Brussels can provide!).

I’ll be in the Perl devroom on sunday, and will give a talk about project management within the Perl community; it’s entitled “Code, Release, Market”. How one can grow a project successfuly is the topic I’ll try to cover. Of course, I’ll use the experience I had so far with Dancer to build the talk.

Well, what esle? Ho yes, Dave Rolsky pointed out that our Changelog format is pretty bad, and well, he’s totally right! We’ll follow his advices and will now build our changelog in a better way.
That’s already the case in the development branch, as you can see on GitHub.

Well, that’s all for now, see you at FOSDEM!

Oh, and maybe, if the gods are with us, we’ll have T-shirts with us!

Perl Moderne, le guide de survie du programmeur Perl

Les éditions Pearson publient le 29 octobre prochain un nouveau venu dans la série “Guide de survie” : Perl Moderne.

Cet ouvrage, co-écrit par Sebastien Aperghis-Tramoni, Philippe Bruhat, Damien Krotkine et Jérome Quelin se veut être l’essentiel des pratiques actuelles en Perl. J’en ai reçu un exemplaire, et je vous propose de vous en faire profiter.

Un rapide coup d’œil à la table des matières donne la couleur: ce livre permettra de guider le développeur Perl, quel que soit son niveau. En effet la première partie est clairement une initiation au langage, tous les principes de base y sont expliqués.
Un débutant pourra donc se référer à la première partie du livre pour apprendre à programmer en Perl, mais un développeur expérimenté ira probablement directement consulter les parties suivantes.

Si cette première partie est clairement consacrée aux débutants, les suivantes interesseront certainement les développeurs Perl plus expérimentés, car elles traitent de tous les sujets importants qui peuvent se présenter dans le quotidien d’un programmeur: la méthodologie Objet (avec Moose), la gestion de données (DBI, DBIx::Class, Fichiers, Sérialisation), la gestion des dates, la programmation événementielle (POE), le parsing de document XML, HTML ou encore la manipulation de requête réseau (LWP).

Ce livre, de part son format et son contenu, me semble être le compagnon idéal du programmeur Perl. Un autre titre aurait probablement pu être “Le meilleur du CPAN, un guide thématique vers l’essentiel pour le programmeur”. Car c’est finalement de cela qu’il s’agit: une sélection éclairée et précise sur ce qui se fait de mieux dans le CPAN pour répondre à des problématiques courantes.

Perl Moderne est publié par Pearson, parution le 29 octobre. ISBN: 978-2-7440-2419-1 (22 €)

Posted in Main

Tags: , ,

Permalink 4 Comments

OSDCfr 2010 slides for Dancer

I finnaly took the time to publish the (Broadway) slides of my OSDCfr 2010 talk about Dancer.

Check them out, it’s Dancer powered!

OSDCfr 2010

OSDCfr 2010 logo

Wow. This year, OSDCfr was a pretty impressive event to stop by. There were many interesting people, such as Tom Preston-WernerGitHub‘s CTO – who did a talk about… well, git, surprinsigly.

From my perspective, the event was even more exciting than I could expect, because I discussed a lot about Dancer, with many people. So I won’t cover the whole event in this blog entry, but I’ll focus on what happened around Dancer.

  • Did my slideshow on saturday’s afternoon, it went pretty well. Everything was powered by Broadway, a small Dancer app I wrote two days before as a proof of concept and as a good excuse to do a live demo. My trick went well, I did not say to anyone I was doing a demo until the slideshow was finished: “Want a live demo? Well, you already had one.” – Good climax (and also, apparently a good way to counter Murphy’s law). In less than 50 lines of Dancer, I have a working slideshow engine with an ajax-based remote controller on my Android phone. Someone who saw it running even told me: “man, you almost have rewrote Apple’s Keynote software with Dancer!”. Cool time.
  • Spoke with Martin Berends who is working on Perl 6 and wants to port Dancer. Martin told me he now has a working PSGI-aware HTTP server for Perl 6 (this is awesome!) and he will now be able to start hacking on the very first step to have Dancer in Perl 6 : the ability to define a route over PSGI, with Dancer’s sugar. During lunchtime, we discussed a bit about how to track memory leaks in Perl (we did find one recently in Dancer and were looking for advices, see below).
  • Did a small hackaton with Franck after the lunch, we were focused on finding where the memory leak came from. We actually did! It’s an auto_reload bug (so it only appears when you start your Dancer app in the development environment with auto_reload set). I was already planning to drop the auto_reload feature, had pretty good reasons to do so, and now, I have just the proof maintaining it is just a pain in the ass. No need to wonder why the Sinatra team also decided to drop that kind of feature from their core. We’ll make a plugin for those who want to still use it, but definitely won’t maintain it in the core.
  • Seen Nicolas Rennert’s talk about Hash-tables alogrithms and thoughts about how to parse a tree, the fast way. This made me think we could refactor the way Dancer parses its route tree, and maybe implement that as a vritual class (the same way we do for template, session or logger engines) in order to be able to switch from one route resolver to another
  • Talked a bit with Philippe Bruhat about his project to write a tool to freeze a Dancer website. Basically, you have a local Dancer app, you run the magic script he has in mind and you get a static website you can just upload somewhere. His idea is interesting and I’m looking forward to see it. Apparently, this will be named WallFlower Pretty good name for a static dancer ;)
  • Did a lightning talk with Franck about Jitterbug, our small continuous-integration tool for Perl project hosted on GitHub. Went pretty fast (we spoke about perlbrew, cpanminus, GitHub web hooks and Dancer, in less than 5 minutes!) not sure if everyone understood what it was about ;)
  • At the end of the conference, did an interview about Dancer with Franck and Philippe Bruhat, for “Linux Magazine France”. More than 40 minutes of live discussion are recorded, Philippe should do a transcript soon. It was really interesting to do, it’s a great overview of the project, I’m sure the paper will be exciting to read.
  • Spoke with some guys of the French Perl Foundation, they offered to sponsor our merchandising needs (basically the T-shirts print costs could be covered by the foundation). They find that Dancer is a good project and deserve their support. That’s great news! I’m honoured :)

Talk Schedule

Random news

It’s been a while since I last blogged here. All is Twitter’s fault! It’s so dumb-easy to spread your news items with Twitter I’ve kinda lost the energy and the motivation to write longer and better-organized blog-entries.

But well, there are at least a couple of things I’d like to share, So here it is, in a random order:

  • I’ve been interviewed by the website “Al Newkirk & Associates” about Perl Dancer. It’s been an interesting experience to answer questions about the genesis of the project and to overview all what happened since the project started in summer 2009. Oh, and the credit for the photograph goes to Rached Ben Mustapha (check out his gorgeous Flickr account), I hope he doesn’t mind I chose this one, but it was the less bad-looking picture of myself I had in stock.
  • There is OSDC 2010 this weekend, the conference that will be held at “Carrefour Numérique, La Cité des Sciences et de l’Industrie”, in Paris will gather cross-language communities. Check out the schedule, it’s pretty rich and I’m sure this will be a very pleasant event to stop by. As you may guess, I’ll speak about Perl Dancer.
  • Dancer’s development continues to go on, we’re in the process of preparing the 1.2 release. It’s really exciting. Bug fixing, documentation updates and packaging issues can be fun! Expect the next CPAN releases to be tagged “DEVELOPER” for the next stable one will be 1.2000!
  • A couple of individuals and companies contacted me to know if it was possible to donate to the Dancer project. Looks like some people are interested in contributing in the project that way. We’re not against that by principle and could use that money in several useful ways for Dancer: merchandising stuff (yes, there will be T-shirts for the 1.2 release), travel costs for Perl conferences, VPS hosting, etc. We’ve opened a GitHub/Pledgie campaign, so if you want to support us, you know where to go ;)

PS: yes, it’s basically a digest of my last tweets, maybe I should write something to automate that ;)

Beyond the strictness you’re used to

Perl is famous as a programming language for letting its users code as they like. The mantra every Perl developer knows is There Is More Than One Way To Do It (even though, it looks like these days, some popular Perl developers are upset when you bring a new solution to a problem, but I digress).

My point is, Perl is like water. It will fit in your bowl, whatever its shape. It’s a language that will reflect your way of thinking most than any other language. I know some Python developers that are pretty in love with their language just because of the opposite spirit: in Python, there should be only one good solution for any given problem. That’s what they like, and what comes together with this philosophy is a very strict language that forces you to be a good citizen.

I can understand that. Strictness is a very good ally for a developer. But I want my strictness. Not the one that comes with the box. The strictness of my programming should be as I want it to be, it’s personal, and if I’m in a team, it should be a set of rules everyone are aware of.

This is were, again, I’m very happy to use Perl.

A couple of weeks ago, at work, I wanted to set a strict Perl environment for my everyday needs. I ended up writing a pre-commit hook that has the following features:

  • filter the code with PerlTidy
  • prevent any commit that violates a Perl::Critic policy
  • run the test suite with Devel::Cover and make sure the total coverage rate is not lower than it was before the commit

Of course, as I said above, I want my strictness, so PerlCritic and PerlTidy use respectively .perlcriticrc and .perltidyrc in the local directory, so I can tweaks the rules on a per-project basis.

After two weeks working with this hook, I realize that my code is now much more robust and very well tested (100% coverage is easy to reach when you start working on a project like that).

If anyone is interested in this commit hook, it’s on GitHub.

Dancer Q&A Hackaton

For your information, a Dancer hackaton is scheduled on the 14th of august (saturday) in order to help the team on different topics:

  • Test the devel branch (which provides a new core and new features)
  • Improve the documentation
  • Improve the test coverage and reach 1k tests (we have 977 so it shouldn’t be difficult ;)

If you like Dancer and want to help, feel free to join us, this will hapen on irc.perl.org, chan ♯dancer, see you there!

Happy dancing.

Dancer, global thoughts about our philosophy

If you follow Perl5 blogs you may have been aware that Dancer was put under the spotlight recently (even if that spotlight was meant to be showing the weak points of Dancer, it was still an enlightenment).

I’m going to use that event as an opportunity to give my point of view on Dancer, this entry will be a reference for exposing the philosophy of the project.

1. Is Dancer a port of Sinatra ?

No. It clearly isn’t. It’s written quite everywhere in the documentation that Dancer was inspired by Sinatra. But the project clearly took its own path.

Don’t expect Dancer to be a Perl 5 clone of Sinatra, it isn’t and will never be. Dancer is a micro-framework, based on the concept introduced by Sinatra. But it provides features of its own, may do things differently and address other issues than Sinatra.

That being said, Sinatra has been a huge source of inspiration.

2. How is Dancer being developed?

Dancer quickly attracted lots of users. Lots of feedback received mentioned “a feeling a fresh air thrown in Perl5″ and we are very glad to see such support from our users. We give a lot of attention to users, we take every suggestion seriously and most of the time, a feature is added because the community itself agreed on the concept.

Dancer is clearly community-driven. As the project-leader, I make decisions when there is some kind of hesitation, but as long as an idea makes sense, I don’t see why I should refuse it.

Dancer is a young project: it’s going to be one year old in august, so we’re aware the code isn’t perfect. That’s why most of our energy is spent in refactoring and bug-fixing. The only priority for me is to release Dancer 1.2 which should be a rock-solid release.

Our code base is very well tested (we have near 1k tests, about 90% of code-coverage).

We are very pleased with the feature-set, our users don’t stop telling us they’re very happy with Dancer, and actually enjoy working with it. This is the best thing that can happen when you do free software: seeing that your work is enjoyed by others).
So, our priority is to make the whole thing robust and well-designed.

Once we have something like that, Dancer 1.2 will be out. And the beer will flow all the night. Yay.

3. How are planned the new features?

One of the attacks was about the fact we stole features from another framework, so I understand people can start thinking this is true.

Of course it’s not. And if it was, I would undestand that as a greeting to the related framework, anyways.

As I said in the section above, we plan our development mostly according to our user requests. Almost all of the issues reported on our tracker originate from our community.

Of course, when a good thing happens somewhere, we may start paying attention to it, like websockets. Some of our users asked for websocket support and we started investigating. I now understand it may look like we started stealing code (what does “stealing” mean if the code is public anyways?) but we’re not, we’re following our users, as we always did.

4. What’s Dancer philosophy regarding other Perl 5 frameworks?

We are definitely Perl lovers. That means we truly think that there is more than one way to do it. Dancer is one way to go. If you don’t choose that way, that’s perfectly understandable, maybe it lacks a feature you have in another framework, maybe you don’t like Dancer’s syntax, whatever the reason, we understand we can’t be the only way to go.

But we know, on the other hand, that Dancer addresses one way to do web development, and it clearly looks like lots of people like that way.

We think that having many frameworks out there is a good thing for Perl 5, and a sign of vitality of the language. We want nothing more than a peaceful cohabition between Perl 5 frameworks. That’s why we don’t think that attacking another framework is a smart thing to do, we don’t see why we should be aggressive if we’re pleased with our project.

We do think that friendly competition is better and let good ideas flow between different implementations.

Let me end this article with Tolkien, in a poetic way:

Three Frameworks for the Elven-kings under the sky,
Seven for the Dwarf-lords in their halls of stone,
Nine for Mortal Men doomed to die,
One for the Dark Lord on his dark throne
In the Land of Mordor where the Shadows lie.

One Language to rule them all, One CPAN to find them,
One PSGI to bring them all and in Plack bind them

Don’t forget, enjoy your code. Whatever happens.

Perl Dancer meeting #1 report

Here is my quick report of the first Dancer meeting that took place last thursday in Paris.

  • We started the meeting by demonstrating how Dancer and Plack middlewares can be powerful and easy-to-use. We did a live demo of a scaffolded Dancer app configured to run with Plack::Middleware::Debug. That was neat. Just editing the config file allows you to enable and disable middlewares, you don’t even need to know about Plack::Builder, Dancer does all the black-magick for you. I ended the demo by showing how to get all your logging messages in your Firebug console thanks to Plack::Middleware::ConsoleLogger and Dancer::Logger::PSGI. That was a piece of cake:
    1. $ sudo cpanm Plack::Middleware::ConsoleLogger Dancer::Logger::PSGI
    2. in config.yml :
      logger: "PSGI"
      plack_middlewares:
        - ConsoleLogger:
      
    3. restart the app with plackup

    And that was it. Impressive :)

  • We talked about the implications of supporting mountable Dancer applications inside Dancer’s core, in order to fix the whishlist item #82. We all agree on the fact that this would allow lots of good things (like generic reusable application bricks); but the rewrite needed is massive. We may wait for 1.2 to be released before starting wroking on that.
  • We plan to write three articles for “Linux Magazine France”. The money earned by those articles will be spent in a pro GitHub account. The first article to be written is an introduction to Dancer, the second one should present PSGI/Plack and the third would explain how to use Dancer with Plack middlewares.
  • Franck plans to work on an asynchronous handler so Dancer can be non-blocking. This would allow support for websockets.

Next meeting will probably occur in september as we may be very few in Paris during august.

Get Adobe Flash playerPlugin by wpburn.com wordpress themes