<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
    <title>Sawyer X</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/" />
    <link rel="self" type="application/atom+xml" href="http://blogs.perl.org/users/sawyer_x/atom.xml" />
    <id>tag:blogs.perl.org,2009-11-03:/users/sawyer_x//87</id>
    <updated>2013-05-02T16:52:04Z</updated>
    <subtitle>A blog about the Perl programming language</subtitle>
    <generator uri="http://www.sixapart.com/movabletype/">Movable Type Pro 4.38</generator>

<entry>
    <title>Interview with Pragmatic Perl in English</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2013/05/interview-with-pragmatic-perl-in-english.html" />
    <id>tag:blogs.perl.org,2013:/users/sawyer_x//87.4638</id>

    <published>2013-05-02T16:33:45Z</published>
    <updated>2013-05-02T16:52:04Z</updated>

    <summary>I was recently interviews to the Russian online Perl magazine Pragmatic Perl. It was a pleasure and truly an honor. The last issue just came out and the interview is appearing there in Russian. If you speak Russian, go ahead...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>I was recently interviews to the Russian online Perl magazine <a href="http://pragmaticperl.com/">Pragmatic Perl</a>. It was a pleasure and truly an honor. The last issue just came out and the interview is appearing there in Russian. If you speak Russian, go ahead and <a href="http://pragmaticperl.com/issues/03/pragmaticperl-03-%D0%B8%D0%BD%D1%82%D0%B5%D1%80%D0%B2%D1%8C%D1%8E-%D1%81-sawyer-x.html#.UYKX10lslKA">read it here</a>.</p>

<p>If, like me, you do not speak Russian, following is the uncensored version in English.</p>]]>
        <![CDATA[<p><strong>    - How and when did you learn to program?</strong></p>

<p>When I was in junior high school there was a programming course offered off school hours. I joined it and learned some basic programming. I didn't really study with the class, I just had fun by myself. Then in the 10th grade I went on computer-oriented studies at school. We studied Assembly, C and Pascal. I actually didn't enjoy learning at school so I was behind the class. At some point I went and bought "A Book on C" and learned by myself instead of in class. When everyone else started the high school project I had already finished it. While everyone wrote a small snake game (we received a basic DOS graphics library to use), I wrote an encryption algorithm implementation cross-compiled for Windows and GNU/Linux with command line interfaces (I had used ncurses on GNU/Linux, specifically).<br />
 <br />
<strong>    - What editor do you use?</strong></p>

<p>I currently use Vim without any plugins or special features. except its excellent syntax highlighting and a few comfortable little tweaks. I tried several plugins but eventually removed them. I find IDE configurations confusing and disruptive. When I need to hack some Perl on Windows, I use Padre, the Perl IDE. I don't really give a shit about editor/IDE wars. Use what you find comfortable, and hopefully try out new things once in a while.<br />
 <br />
<strong>    - When and how have you been introduced to Perl?</strong></p>

<p>When I was in high school I met a hacker at hardcore punk shows who programmed in Perl. He was really cool and suggested I give it a shot, so I tried it and had a blast. Been using it ever since!</p>

<p><strong>    - What are other programming languages you enjoy working with?</strong></p>

<p>I used several languages throughout the years (notably Assembly, C, C++, Ruby and Python) but honestly, the only language I really enjoyed working with is Perl. C was fun too, but from a different direction, I guess. Perl definitely takes the cake... err.. or onion.</p>

<p><strong>    - What do you think is the most strongest Perl advantage?</strong></p>

<p>Technically-wise? Elasticity. Perl is not just flexible, it's elastic. You can move walls around, you can bend them, it's like the fucking matrix! Devel::Declare is just a reminder that literally anything can be accomplished in Perl. You are mostly limited by your own imagination.</p>

<p>I think what draws me and developers like me to Perl is the easiness of accomplishing things in Perl, since it just bends the world to your point of view, whatever it may be. So, if you can speak it, you can write it in Perl!</p>

<p><strong>    - What do you think is the most important feature of the languages of the<br />
      future?</strong></p>

<p>Parallelism and community, hands down. At least to me.</p>

<p>Speed of execution is important, surely, but proper parallel execution seems to me like it's becoming more and more important. I reckon that's why Perl 6 has put so much weight on that.</p>

<p>Still, as much as parallel execution and speed are important, there is a limit to how involved you are when all you have is syntax. I mean, having a great language is... great, but having a community around it gives you a sense of belonging, which is one of the most basic instincts and desires we have as animals. We want to belong, to be part of something, to create for ourselves, for others, with others, and see it blossom and take shape. We want to exist and create existence. Community is exactly that. If we want a language that is sustainable beyond its technical capabilities, we need to have a good community, to make it more than just a logistical assortment of characters. It needs to be about people.</p>

<p><strong>    - What drives you in being so active in Perl community and open source in<br />
      general?</strong></p>

<p>Several things do:<br />
1. I like creating. The first time I picked up a guitar, I didn't learn a song, I tried writing my own. I wanted to create something new. Open source and free software promote that idea. They say "let's make something!" - Perl is centered around that. Perl always says "don't be afraid to try, don't be afraid to fail".<br />
2. I like complaining about things and fixing them. I've become very good at pointing at things and saying "that sucks", and I'm improving at trying to fix things that suck. Open and free code allows you to do just that. It pushes you to get involved. Perl is a tremendous example of getting people involved. If you look at how many Perl programmers are working on more than one or two or ten or more projects at the same time, it's quite stunning. You get people involved in over dozens of projects throughout a single year. It's absolutely crazy. Look at rafl! He's everywhere!<br />
3. I like cooperating with people. If there's anything more motivating, it's the ability to work with others. I get to cooperate with the smartest people I've ever met. Perl has some of the greatest minds out there. The vast majority of them are pretty fucking awesome people and I'm thrilled to have met them and be considered a friend to at least some of them. There's generally something very exhilarating about working with others towards a common goal. It fills you with purpose and satisfaction.</p>

<p><strong>    - You seem to write lots of async code. Why did you choose AnyEvent while<br />
      everybody else bashes it?</strong></p>

<p>I actually started with POE. When I tried to wrap my head around it, a long time ago, I went to the IRC channel and asked. People tried to get me to write an event loop to understand it better. This one person, after an hour of me doing random things, asked me "what don't you understand exactly?" He worked with me for a good half hour explaining POE, and helped me understand it. I later found out it was Rocco Caputo, the creator of POE.</p>

<p>I decided to try AnyEvent because of its slimmer interface and better speed. I still like POE (and Reflex looks impressive) but it's a bit too verbose for me. I will probably get to work on some Reflex stuff in the future though, and I'm excited about that.</p>

<p>I haven't noticed people bashing AnyEvent as much as expressing disdain for the way the author (Marc) has occasionally expressed himself and at least one decision to break a module that he considers misusing the AnyEvent API. I'd rather not get into it too much, except that I agree on some things and disagree on others. Besides, there's a lot I don't know about it.</p>

<p>The only thing that troubles me is that AnyEvent didn't pick up as a community. I hope that will change in the future.</p>

<p><strong>    - You've joined the Dancer project quite early. Why do you think it attracted you?</strong></p>

<p>Few things: how small it was, how thin the interface and DSL were and how warm the IRC channel was. Back when I started, there were three or four people in the channel, if I recall correctly.</p>

<p>When I wrote my first program with Dancer, I thought it couldn't handle CGI (I didn't even grep PSGI yet) and I wrote a blog post saying "too bad it can't, it looks kind of cool". That evening I went to eat hummus with my girlfriend and spent a few minutes checking online if someone had tried Dancer with CGI. I saw a post by someone saying "Sawyer wrote about Dancer and that it doesn't support CGI, but it does. This is how you should configure it!" - that was Alexis Sukrieh, who wrote Dancer. I was pretty amazed that he saw my post and had written an entire post back. It was so cool. That's when I joined the IRC channel.</p>

<p>The ease of helping out in Dancer and working on it with others was very compelling. You were a part of it as soon as you stepped in, and that just made me feel so wonderful working on it. People in the community are kind and thoughtful, and you always feel like investing time in Dancer is worthwhile for the Dancer users community and for the general Perl community.</p>

<p><strong>    - Tell us about your role in TelAviv.pm and group in general. Do you think<br />
      community meetings are important?</strong></p>

<p>There had been a few organizers to Israel.pm, prominently Shlomi Fish and Gabor Szabo. After Shlomi decided to step down from organizing the meetings, I decided to try and organize it and boost the attendance. I called it TelAviv.pm because we met at the Tel Aviv university. Pretty quickly though we moved it to a place in Ramat Gan, which is 20 minutes from Tel Aviv but has its own municipality. I still kept the name anyway, since it's like a part of the larger Tel Aviv area (which is silly, since Tel Aviv is really small to begin with). I set up a crappy website (later revamped to a good website) and contacted people to give talks and gave quite a few myself as well. For the past few years I've organized the meetings, occasionally assisted by Shlomi or Gabor, who are both still active members in the community. The past few months we've decided to have each meeting organized by someone else. It was very successful. We have also successfully organized two fantastic Israeli Perl Workshops.</p>

<p>I think community meetings are extremely important! By going to meetings you can:<br />
- Improve your knowledge of the language and its third-party modules<br />
- Learn tricks of the trade<br />
- Meet potential co-workers and employers<br />
- Practice giving talks<br />
- Making friends and possible cooperators<br />
- Get free help with work or ideas you had<br />
- Have a good time</p>

<p>It sometimes seems like it's not worth it, but once you start attending, let your guard down and meet new people, you begin to realize how incredible it is. It's like a free drug that makes you feel better, become smarter and better at your job without any side-effects except loss of time. :)</p>

<p><strong>    - You tweet a lot about your git experience. What is so special about this vcs?</strong></p>

<p>Git is one of the best tools for any creator, whether a writer, a programmer or even a graphics artist. Sure, there are other tools, but they all suck in comparison. Git is small, fast and powerful. In a way, it's like the Perl of version control systems.</p>

<p><strong>    - You've visited Romania recently. What did you do there?</strong></p>

<p>I had the honor of attending the Cluj.pm anniversary meeting. I gave a few talks and hung out with great people. I've written a detailed report available here: http://blogs.perl.org/users/sawyer_x/2013/03/clujpm-anniversary-meeting-report.html. In a nut-shell? Go there! Meet these people! Attending their conferences! We all have so much to learn from them!</p>

<p><strong>    - Your talks at the tech events are very positive and energetic. What's your<br />
      secret?</strong></p>

<p>Thank you. :)</p>

<p>I guess I just think that what we have in the Perl community, both technical and social, is so fucking great, that it's hard to hold back.</p>

<p>There are so many exciting and fun things in Perl. When you look at other communities, at other languages, it doesn't seem like they have any glaring advantages (and many them don't have any advantages at all) but they know how to get excited about what they have. They show you some module that you know already exists in Perl for 7 years, but they get really worked up! In Perl you can write something amazing and people will just reply with a calm "cool" and that's it. We need to get worked up, we need to get excited, we need to realize how fantastic what we have is and to be ecstatic about it!</p>

<p>Another considerations in how I give talks is that if the talk isn't fun, you don't really learn much. It's hard to stay focused when it's just raw material. On a technical level it might be interesting, but you have to present it in an interesting and compelling manner. Look at Paul Fenwick and his talks. Can you imagine anyone not listening to him and learning from him? So of course none of us can be Paul (even Paul works very hard to be Paul), but we can do a hell of a lot more than just presenting a piece of code. We own our conferences and meetings, don't we? Let's have fun with it!</p>

<p><strong>    - Where do you work right now? How much of your time do you spend writing in<br />
      Perl? You've mentioned somewhere that you're an administrator too, is that<br />
      still true?</strong></p>

<p>I currently work in two companies: an e-commerce platform and a VoIP startup. I'm fortunate enough to have an amazing boss that lets me to work on a ton of Perl. I started with 50% of my time on Perl and 50% on systems administration. Once I stabilized the infrastructure, I was able to program more of it in Perl instead of chasing my own tail (which systems administrators do a lot). That way I got a stable ground and then started writing major components of the infrastructure in Perl. Nowadays about 80% of my time is spent writing Modern Perl, as part of the infrastructure and surrounding services.</p>

<p>At least until recently, because in June I will be moving to Europe and will be taking a different job. I will probably blog about it when the time is right.</p>

<p><strong>    - Should we encourage young progammers to learn Perl?</strong></p>

<p>Definitely! We just need to know how to be fucking excited about it. It takes time to realize why a certain solution is elegant, why a piece of code is nothing short of a work of art. Hell, it takes time for all of us to understand. Young programmers, who have even less experience, do not easily understand why Moose is spectacular. We need to be able to convey this. We need to be able to draw their interest in more than our experienced background, but in their inexperienced view. We need to speak their language and get them hooked. They will slowly learn to appreciate things from a more refined aspect, so we shouldn't worry about that now. Now, we should get them thrilled, get them interested.</p>

<p><u><strong>    Questions from our readers (some of them are jokes :):<br />
</strong></u></p>

<p><strong>    - Is Sawyer your real name?</strong></p>

<p>Actually, No. It's a nickname my closest friends gave me a long time ago. It comes from the fictional character Tom Sawyer. There is a story behind it, but I'll keep that for another interview. :)</p>

<p>If you're ever unsure about calling me Sawyer, think of it this way: I always prefer to make a friend, so feel free to call me the way my friends do!</p>

<p><strong>    - Why do you swear as 5 yo?</strong><br />
(note: this is in regard to a comment I made at YAPC::NA 2012 saying "I was swear like a 5 year old")</p>

<p>That was a slip of the tongue, I'll admit. I meant to say "13 year old". I guess swearing is one of the instruments I use to put emphasis when speaking. I mean, it's fucking noticeable! I also grew surrounded by trashy American action movies and profanities in Israel are generally very common, so I suppose my speaking patterns adjusted to all of that. Horrible, isn't it? :)</p>

<p><strong>    - So, did you have a drink with Sebastian Riedel?</strong></p>

<p>Not yet. I certainly hope to do so!</p>

<p>I got to meet Glen Hinkle who's a charming person. I hope next time I see him I'll be able to sit down with him some more and chat.</p>

<p><strong>    - Are you going to visit YAPC::Europe in Kiev this year?</strong></p>

<p>I was supposed to attend, then couldn't, and now there's a chance I might be able to attend anyway. I can't make promises because people get mad at me when I cancel, but it just might be possible for me to attend in the end. The question is how late could I submit talk proposals. :)</p>]]>
    </content>
</entry>

<entry>
    <title>Why You Should Help Crowd-fund Pinto</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2013/05/why-you-should-help-crowd-fund-pinto.html" />
    <id>tag:blogs.perl.org,2013:/users/sawyer_x//87.4633</id>

    <published>2013-05-01T08:13:31Z</published>
    <updated>2013-05-01T09:20:45Z</updated>

    <summary>There are only a few more days left to chip in to sponsoring work on Pinto. If you&apos;re still unconvinced or haven&apos;t thought about it yet, let me give my point of view on why you should spare a few...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>There are only a few more days left to chip in to <a href="https://www.crowdtilt.com/campaigns/specify-module-version-ranges-in-pint">sponsoring work on Pinto</a>. If you're still unconvinced or haven't thought about it yet, let me give my point of view on why you should spare a few minutes and a few bucks to sponsor Pinto.</p>]]>
        <![CDATA[<p><strong>Perl Awesome Sauce</strong><br />
One thing that took a while for us to realize is that, if we want to showcase Perl, we need to create great things in Perl. It can be a beautiful game, a useful utility or a funny program. It needs to be something someone can point to, and say "hey, that's Perl for ya!"</p>

<p><a href="https://metacpan.org/module/Pinto">Pinto</a> is just that. Pinto is such a useful utility that it makes it easier for companies to use Perl more intensively. It allows anyone (whether a company or a single programmer working on personal or contract work) to easily maintain a CPAN-like repository of Perl modules, whether from CPAN or not. It helps manage this repository to add new company modules, new CPAN modules, pin versions, upgrade and so on and so on. It basically makes it possible to effortlessly maintain your own CPAN, within the workplace (or home) while still using modern tools like cpanminus.</p>

<p>Considering a major issue for companies is keeping code uniformed, properly stored and comfortably installable, Pinto provides a crucial service in an elegant and graceful manner.</p>

<p>Supporting Pinto means supporting more Perl Awesome Sauce from a developer who had already contributed greatly by giving us <a href="https://metacpan.org/module/Perl::Critic">Perl::Critic</a>.</p>

<p><strong>Toolbox Investment</strong></p>

<p>I think of Pinto as more than just nifty. I think it is going to be a crucial centerpiece of any proper environment. I can't think of a company I worked for, that had proper Perl code, that wouldn't have a use for Pinto. Instead, any company I think about could use it. Any company I worked at could have utilized it to make their work (and my work!) much easier and much more flexible.</p>

<p>I'm certain that in the future we will see Pinto's proper place in our immediate toolbox. Why not invest now? Why not make sure we'll have a great tool?</p>

<p><strong>Community Outreach</strong></p>

<p>I'm pretty certain that it wouldn't be difficult to get more funding to Pinto via companies, TPF grants, EPO initiatives, and other such methods. The major benefit to crowd-funding is that you get the community to wake up and step up to the plate. If all Perl users would be part of the community, we would be so much bigger, but we suffer from what I would call a "woodwork syndrome" which is a bountiful of people who are not part of that community. However, many of these people are in-tuned to other websites. This includes Slashdot, Digg, but not only news websites. Some of these can be crowd-funding websites like Crowdtilt and Kickstarter. Some of these are websites that write or tweet about projects that get crowd-funded.</p>

<p>By getting this project funded, you're notifying the world on a lively Perl project and community. You're advertising your language and your language's awesome sauce to the world.</p>

<p><strong>Opening Your Own Door</strong></p>

<p>Most importantly, Pinto is not the only project that could (and should) be crowd-funded. There are plenty of others. Pinto is just the beginning. Since your project could be next, wouldn't you want to have a good beginning? Sure you would! This is why you should chip in a few bucks ($1 and up) and help us all, as a community, fund this today, and hopefully yours tomorrow!</p>

<p>Hey, look at that! <a href="https://www.crowdtilt.com/campaigns/specify-module-version-ranges-in-pint">Here's the link again!</a><br />
</p>]]>
    </content>
</entry>

<entry>
    <title>My Perl Pitch to Students</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2013/04/my-perl-pitch-to-students.html" />
    <id>tag:blogs.perl.org,2013:/users/sawyer_x//87.4575</id>

    <published>2013-04-15T14:02:59Z</published>
    <updated>2013-04-15T14:12:34Z</updated>

    <summary>I blogged about visiting Evozon and giving a Perl pitch talk to students, trying to get them interested in Perl. I&apos;ve decided to share the draft I wrote a day earlier with the ideas I wanted to express. So, here...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>I blogged about visiting Evozon and giving a Perl pitch talk to students, trying to get them interested in Perl. I've decided to share the draft I wrote a day earlier with the ideas I wanted to express. So, here it is:</p>]]>
        <![CDATA[<p>Do you like games? Because you can create games in Perl!<br />
Do you like biology, stuff like sequencing the human genome? People do that in Perl!<br />
Do you like web programing, creating websites and awesome web services? You can do that in Perl!<br />
How about writing security tests? Writing exploits is often done in Perl!</p>

<p>See, you probably don't know what you want to do yet, and that's fine. It takes time for all of us to finally understand what we want to do. The great thing about Perl is that whenever you're ready, and whenever you know what you want to do, Perl is there. Perl is a language that allows you to take your time in deciding what you want to do, and when you finally know what it is - you could use Perl for it. It will just work.</p>

<p>Perl has a wide variety of modules written by people like you and me. There's the CPAN (Comprehensive Perl Archive Network), which is where we upload all of these modules. Anyone can join, anyone can contribute. You get free support, an issue tracker, a testing framework, and everything. You get people to help you out, and improve your code and knowledge and understanding, and you get to help other people. It's incredible. No other language has this much third-party components. It really is crazy!</p>

<p>But Perl is not just a strong, fast, open, free, and incredibly flexible language, but it also stresses community. You'll notice I don't speak Romanian. That's because I'm Israeli. I came here for a Perl meeting. Perl has lots of meetings and conferences. Perl has the most conferences world-wide than any other programming language. This isn't by accident. It's because we care about community. We have close to 4 big conferences (400-900 people) and dozens of conferences of smaller magnitude of 40-120 people - just about Perl. We meet, we drink, we talk about stuff, we even learn and teach each other new skills. We form not just professional connections, but actual friendships. We're all friends, and it's very rare, and very special. Nothing really can compete with that.</p>

<p>Perl is not just a profession or a skill, it's a home.</p>]]>
    </content>
</entry>

<entry>
    <title>Cluj.pm Anniversary Meeting Report</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2013/03/clujpm-anniversary-meeting-report.html" />
    <id>tag:blogs.perl.org,2013:/users/sawyer_x//87.4475</id>

    <published>2013-03-25T19:46:43Z</published>
    <updated>2013-03-25T21:46:44Z</updated>

    <summary>So, I went to Cluj.pm&apos;s anniversary meeting this month. It&apos;s been a year since Cluj.pm was formed and I&apos;ve been lucky enough to be invited to the event. Here&apos;s my report of it....</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>So, I went to <a href="http://cluj.pm/">Cluj.pm</a>'s anniversary meeting this month. It's been a year since Cluj.pm was formed and I've been lucky enough to be invited to the event. Here's my report of it.</p>]]>
        <![CDATA[<p>The Cluj.pm meetings are sponsored and organized by <a href="http://www.evozon.com/">Evozon</a>. Evozon work with multiple languages and handle various ambitious projects, but it seems as though Perl has an especially warm spot in their heart. They also sponsored YAPC::EU 2012 in Frankfurt.</p>

<p>I've been consistently surprised by the amount of work and care done by Evozon in organizing the Perl meetings of Cluj.pm. They advertise it well, they invite guest speakers, they design and print out custom nametags, pick selective locations that could host everyone, sponsor drinks, etc. Hell, they even provide complimentary beer with a custom label relating to the event ("A camel walks into a bar..."). Oh yeah, and prepared a fantastic cake of the group logo I was given the honor to cut first.</p>

<p>I gave three talks at the event. I was told they were successful, first by people who cynically thanked for being placed after my talks with a friendly poke, and second by actual feedback pages. Yes, you read that right. Cluj.pm meetings have feedback input! You list what you liked, what you didn't, and what you would like to see, and you rate your experience, the event organization, the speakers and the subjects - just like with YAPC.</p>

<p>I kept hearing from the organizers that they're still a young group and they have much to learn, but they're in the right path. Some of you might be thinking if there is something they've done wrong. No, none. They've actually got so many things right, I think it's crucial to list at least some of them:<br />
<ul><br />
	<li>They found an awesome venue</li><br />
	<li>They get (and sponsor) guest speakers</li><br />
	<li>Promotional material like nametags, beers</li><br />
	<li>A freaking cake!</li><br />
	<li>Feedback from attendees</li><br />
	<li>They have multiple female speakers and multiple female attendees (yes, it's important!)</li><br />
	<li>Multiple people (including female) giving their first talk (they use incentives to get people to try - it's brilliant!)</li><br />
</ul></p>

<p>The evening was a great success. I had a blast! The talks were interesting, the speakers were fun, the audience was warm and welcoming. We stayed up until a late hour, chatting, rambling, drinking, eating and having a very good time.</p>

<p>The following day I got to speak in front of students at Evozon. They have an intern program that allows students to apply to Evozon (without dropping out of school), possibly be hired and do an internship. Afterwards they might find a permanent job. I was asked to speak about Perl, hopefully providing the students with incentive to consider the Perl department for their internship application.</p>

<p>I started with the fact that most of them probably don't know yet what they want to do, whether it is web programming, networking, security research or even graphics, but whenever they will, Perl will be a useful language to know, and they could utilize it for whatever they chose. I explained about the strengths of Perl, but the bottom line was, really, its community. You don't just create professional connections, you form actual friendships. My main point, in a line, was: Perl is not just a profession or a skill, it's a home. I was told the applications for Perl afterwards spiked, by students who had only heard about the language for the first time. (perhaps some was due to an example I gave on making 708,000 requests in 6 minutes to find actors across 42 seasons of 6 TV series)</p>

<p>If you think I was exaggerating about the comment on the Perl community being a home, a good demonstration of it is my time in Cluj. Every single day people from Cluj.pm had made it their mission to make sure I don't get bored, hang around with people instead of stashing myself at the hotel, go out and get some air and see the city, have a good time. They kept me company and made countless efforts to make sure I had everything I needed and more. It was quite overwhelming and touching. I truly felt I had made new friends who care a lot about me.</p>

<p>I had an incredible time, and I owe a huge thanks to Evozon, to Cluj.pm, to Amalia, Anca, Darius, Horea, Natasha, Mircea, Mihai, Diana, Raluca, Mirela, Marius, Arpad and at least a dozen other people who made my experience simply delightful. Nothing echos my message to the students about community as much as the wonderful treatment I received.</p>

<p>I already miss it all. :)</p>]]>
    </content>
</entry>

<entry>
    <title>Recursive deferred promises</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2013/03/recursive-deferred-promises.html" />
    <id>tag:blogs.perl.org,2013:/users/sawyer_x//87.4434</id>

    <published>2013-03-15T10:46:31Z</published>
    <updated>2013-03-17T11:46:32Z</updated>

    <summary>Hey, &quot;recursive deferred promises&quot; might sound like a smashingly complex idea, but really, it isn&apos;t. Here&apos;s the what, why and how....</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>Hey, "recursive deferred promises" might sound like a smashingly complex idea, but really, it isn't. Here's the what, why and how.</p>]]>
        <![CDATA[<p>The <a href="http://en.wikipedia.org/wiki/Futures_and_promises">promises pattern</a> is very useful for asynchronous code which tends to lead to "arrow-head" formation in code structure. It allows to continually develop in a form that seems blocking, while handling both success and failure in a comfortable, sane manner. I'm sorry I was not aware of it when I gave my "Asynchronous Programming" talk in YAPC::EU 2012.</p>

<p>Fortunately for us, we are lucky to have such skilled, cool, and handsome people as <a href="https://metacpan.org/author/STEVAN">Stevan Little</a> and <a href="https://metacpan.org/author/PEVANS">Paul Evans</a>, to implement <a href="https://metacpan.org/module/Promises">Promises</a> and <a href="https://metacpan.org/module/Future">Future</a>, respectively, for us in Perl. Nowadays for my more complicated projects, I use Promises with joy. Stevan and Paul, each in their developed modules, have provided numerous examples (and introductory text) to how this pattern works and how to use it in various situations. Also, they are (as always) more than helpful when asked for pointers.</p>

<p>Letting go of my crush of Stevan and Paul for a bit, I'd like to explain a specific issue that troubled me in a project, which lead me to write recursive promises. What is it, why did I need it and how did I accomplish it? I'll be using the <a href="https://metacpan.org/module/Promises">Promises</a> module, though the principle is exactly the same as in the <a href="https://metacpan.org/module/Future">Future</a> module.</p>

<p>I have a project which deploys a new server. This requires raising a ticket to create an instance, monitoring the status, and then running commands on it sequentially. First command updates, the next installs some prereqs, the one after that installs the deployment infrastructure and the last one is run locally to deploy our code to the server. This clearly leads to the arrow-head format:</p>

<pre><code>
run_remote_command $host, 'aptitude update && aptitude safe-upgrade', sub {
    # check possible fail or succeed
    run_remote_command $host, 'aptitude install build-essential curl...', sub {
        # check possible fail or succeed
        run_remote_command $host, 'gem install chef...', sub {
            # check possible fail or succeed
            run_local_command 'chef solo cook ...', sub {
                # check possible fail or succeed
            }
        }
    }
};
</code></pre>

<p>Not so pretty, is it? Well, I can use promises to make it more manageable:</p>

<pre><code>
use Promises 'deferred';
my $def = deferred;
run_remote_command $host, 'aptitude update && aptitude safe-upgrade', sub {
    if ( my $result = shift ) {
        $def->resolve($result);
    } else {
        $def->reject("Failed update/safe-upgrade");
    }
};

<p>$def->promise->then( sub {</p>

<p>    my $def = deferred;<br />
    run_remote_command $host, 'aptitude install build-essential curl...', sub {</p>

<p>        if ( my $result = shift ) {<br />
            $def->resolve($result);<br />
        } else {<br />
            $def->reject("Failed update/safe-upgrade");<br />
        }<br />
    } );<br />
    return $def->promise;<br />
}, sub {<br />
    my $error = shift;<br />
    die $error;<br />
} )->then( sub {<br />
    my $def = deferred;<br />
    run_remote_command $host, 'gem install chef...', sub {<br />
        if ( my $result = shift ) {<br />
            $def->resolve($result);<br />
        } else {<br />
            $def->reject("Failed installing chef");<br />
        }<br />
    } );<br />
    return $def->promise;<br />
}, sub {<br />
    my $error = shift;<br />
    die $error;<br />
} );<br />
...<br />
</code></pre></p>

<p>You get the idea, right? Create a deferred promise, resolve or reject it later, and pass back the promise itself. Use the promise returned to chain more promises with deferred promises that resolve or reject later. Very nice. If you have a hard time following this, try <a href="https://metacpan.org/module/Promises::Cookbook::ChainingAndPipelining">this cookbook</a>.</p>

<p>My problem was having to hardcode all the commands and have a known list of commands in advance, in order to write a promise step for each. You cannot have an arbitrary number of promises steps. At least not too easily. I wanted an array of any number of commands that will be run separately in each promise step. My solution was a recursive deferred promises pattern (at least that's how I'm calling it for now - trademarked!), illustrated in this Github gist:<br />
<script src="https://gist.github.com/xsawyerx/5152738.js"></script></p>

<p>As you can see, I set up the first promise and chain it to a code reference that calls itself recursively until the array of actions is exhausted. A good point made by <a href="https://metacpan.org/author/NPEREZ">Nicholas Perez</a> was that instead of defining a variable for the callback and only then defining it as a coderef (thus allowing it to call itself), I could have used the new <a href="http://perldoc.perl.org/functions/__SUB__.html">__SUB__</a> option more modern Perls (since Perl 5.16) have. In production my code has to be more backwards compatible, so I had to use my method instead.</p>

<p>Epilogue, sort of:<br />
The one thing I want you to take from this post is not that I'm cool (although I am, very much so - you should definitely consider being my friend), but rather that when we talk about creating cool stuff (re: <a href="https://metacpan.org/author/GENEHACK">John @genehack Anderson</a>'s talk on this), we talk about stuff like Future and Promises. That's an example of writing something awesome, even if we didn't invent the concept. If you look at the code of Promises, for example, it's not even complicated or hairy. It's short, clean and elegant, and it provides a great service for programmers, and a wonderful standing point when we want to promote Perl as a strong and modern language. "Futures/Promises? Oh yeah, we got that!"</p>]]>
    </content>
</entry>

<entry>
    <title>MooseX::Role::Loggable improvements (version 0.110)</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/12/moosexroleloggable-improvements-version-0100.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.4102</id>

    <published>2012-12-04T12:55:54Z</published>
    <updated>2012-12-05T10:33:49Z</updated>

    <summary>I&apos;ve released a new version of MooseX::Role::Loggable: 0.110. It provides some improvements and basically a more steady version of it. Here&apos;s a description of what it is, what the improvements are, and some of the considerations in doing them....</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>I've released a new version of <a href="http://p3rl.org/MooseX::Role::Loggable">MooseX::Role::Loggable</a>: 0.110. It provides some improvements and basically a more steady version of it.</p>

<p>Here's a description of what it is, what the improvements are, and some of the considerations in doing them.</p>]]>
        <![CDATA[<p><strong>What is MooseX::Role::Loggable?</strong></p>

<p>It's a <a href="http://p3rl.org/Moo">Moo</a>/<a href="http://p3rl.org/Moose">Moose</a> role (works with both) that allows you to provide comfortable and strong logging capabilities to your objects. It uses <a href="http://p3rl.org/Log::Dispatchouli">Log::Dispatchouli</a> to allow you to connect to various logging outputs. You can work with files, stdout, stderr, and Syslog. It has levels, facilities, identity, debugging mode, muted logging, fatal logging, and control over the path and name of the log files (if that's what you chose to use).</p>

<p>Along with methods (such as <em>log</em> and <em>log_debug</em>), it provides attributes with sane defaults to allow your application to work without doing any additional work. For example, you get a <em>debug</em> flag and the <em>log_debug</em> method will only output something if the flag is on.</p>

<p><strong>Changes introduced:</strong></p>

<p>Other than documentation improvements, I've introduced two major changes: setting the <em>logger_ident</em> attribute automatically and deprecating the <em>log_fields</em> method.</p>

<p><strong>The identifier:</strong></p>

<p>The <em>logger_ident</em> attribute is the application's identifying string for the logging. The default was set incorrectly to the name of the role, instead of the name of your class. Now it is set correctly to whatever your application's class name is.</p>

<p>If your have an application called MyApp::Worker, and it uses the role, the ident will be set to <em>MyApp::Worker</em>. This makes all logging instinctively clear for you in all your logs.</p>

<p>Of course, you can always set it to whatever you want by overriding the attribute in your class.</p>

<p><strong>The logger fields:</strong></p>

<p>Sometimes you have object MyApp, which uses the logger role, and you want to create another object (say, MyApp::Worker) which needs to have the exact same logging capabilities. The method <em>log_fields</em> was added in order to provide all the configuration for the child object. That wasn't very smart.</p>

<p>Instead of passing the attributes, you can simply pass the logger (Log::Dispatchouli) object, available in the <em>logger</em> attribute, as such:</p>

<pre>
MyApp::Worker->new( logger => $self->logger );
</pre>

<p>However, this created a problem. You see, MooseX::Role::Loggable provides attributes which are then used to create the logger object automatically. They have their own defaults as well. If you provide a logger yourself, you're ignoring the attributes, and the attributes no longer reflect the object you have passed. That's the problem.</p>

<p>MyApp might have the debug flag set to on. If it passes the logger to MyApp::Worker, it will have a debug-mode logger, but MyApp::Worker's debug flag attribute will be set to the default, which is off. The logging will work, yes, but probing your secondary object (like checking its debug flag) will be incompatible with what the logger actually has.</p>

<pre>
$worker->logger->{'debug'} == 1; # true
$worker->debug == 1; # false, uses default value: 0
</pre>

<p>The way to fix it was to check whether a logger was passed to the object and if so, change the values of the attributes in the object to match the ones defined in the logger object that was passed. I used the <em>BUILDARGS</em> method for that.</p>

<p>Another tricky corner is making sure that you still allow the user to provide a logger <strong>and</strong> to override something in that logger. For example, a user might want to pass the logger, but enable debugging, which isn't on:<br />
<pre><br />
$self->debug == 0; # true<br />
# pass the logger, but also turn debugging on<br />
MyApp::Worker->new( logger => $self->logger, debug => 1 );<br />
</pre></p>

<p>This sacrifices the immutability of the logger somewhat (and I'm a *big* fan of immutability) but I think that's a plausible usage case, so I'm allowing it.</p>

<p>If you're already using the <em>log_fields</em> methods, you should stop. It will still work now (passing on the <em>logger</em> attribute for you), but it's deprecated and will emit a warning both in your terminal and in your logs. Why both? Because I have no idea which is active, and I want to make sure you don't miss it, because <strong>will</strong> remove it later on.</p>]]>
    </content>
</entry>

<entry>
    <title>Dynamic ACL for EC2 with Dancer</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/11/dynamic-acl-for-ec2-with-dancer.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.4021</id>

    <published>2012-11-05T08:06:05Z</published>
    <updated>2012-11-05T08:30:56Z</updated>

    <summary>An in-house Dancer webapp that&apos;s running on EC2 needed an ACL (Access Control List): a list of IPs that are allowed to access the application. Here is how we&apos;ve accomplished it in a few lines....</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>An in-house <a href="https://metacpan.org/module/Dancer">Dancer</a> webapp that's running on EC2 needed an ACL (Access Control List): a list of IPs that are allowed to access the application. Here is how we've accomplished it in a few lines.</p>]]>
        <![CDATA[<p><strong>Creating the ACL</strong><br />
We wanted to probe EC2 for all the machines on all regions that have a specific name. We're using <a href="https://metacpan.org/module/VM::EC2">VM::EC2</a>, which can probe the regions to give us all regions dynamically, and can search for instances in a region. The only consideration is that you have to initialize <a href="https://metacpan.org/module/VM::EC2">VM::EC2</a> objects with a region (or full endpoint) when you want to find instances.</p>

<p>The code looks like this:<br />
<pre><br />
my @acl = map { $_->ipAddress }<br />
          map {<br />
            VM::EC2->new( -region => $_->regionName )<br />
                   ->describe_instances(<br />
                       -filter => { 'tag:Name' => 'worker' }<br />
                   )<br />
          } VM::EC2->new->describe_regions;<br />
</pre></p>

<p>We create a new <a href="https://metacpan.org/module/VM::EC2">VM::EC2</a> object, and call the <em>describe_regions</em> method, which retrieves the list of available regions in EC2. Then we go over reach region and create a new <a href="https://metacpan.org/module/VM::EC2">VM::EC2</a> object for that region and search for all instances that match a specific <em>Name</em> tag. Then we access the <em>ipAddress</em> attribute to get the public given IP address that EC2 has given that instance. It all funnels into an array, so we end up with an array of IP addresses.</p>

<p><strong>Enforcing the ACL</strong><br />
NOTE: this could also be done using <a href="https://metacpan.org/module/Plack::Middleware::Access">Plack::Middleware::Access</a>, but it still provides some insight into <a href="https://metacpan.org/module/Dancer">Dancer</a>, and gives you more finer-grained control over the result.</p>

<p>To make sure <a href="https://metacpan.org/module/Dancer">Dancer</a> enforces the ACL for each and every request, we simply add a <em>before</em> hook that checks if the IP is acceptable. If it is not, we return a <a href="https://metacpan.org/module/Dancer::Error">Dancer::Error</a> response.</p>

<p>This is what <a href="https://metacpan.org/module/Plack::Middleware::Access">Plack::Middleware::Access</a> does, but if we wanted, we could go beyond and log it, and forward it to a login page which will create a cookie and start checking for that cookie in the <em>before</em> hook, or... well, there are a lot of ideas. I'll leave them to you.</p>

<p>The code looks like this:<br />
<pre><br />
hook before => sub {<br />
    my $address = request->remote_address;</p>

<p>    grep { $_ eq $address } @acl<br />
        or return Dancer::Error->new(<br />
            code    => 403,<br />
            message => 'Access denied',<br />
        )->render;<br />
};<br />
</pre></p>

<p>Enjoy.</p>]]>
    </content>
</entry>

<entry>
    <title>Net::Icecast2 is out!</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/11/neticecast2-is-out.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.4017</id>

    <published>2012-11-04T14:19:00Z</published>
    <updated>2012-11-04T17:40:56Z</updated>

    <summary>My friend and co-worker Pavel Zhitomirsky, who also organized the last TA.pm meeting, has made his second CPAN contribution: Net::Icecast2. While trying to work with Icecast, he found that there is no Icecast 2 API on CPAN and decided to...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>My friend and co-worker Pavel Zhitomirsky, who also organized the last TA.pm meeting, has made his second CPAN contribution: <a href="https://metacpan.org/module/Net::Icecast2">Net::Icecast2</a>.</p>

<p>While trying to work with Icecast, he found that there is no Icecast 2 API on CPAN and decided to write one. As usual, he writes Modern Perl with all the usual bells and whistles: <a href="https://metacpan.org/module/Moo">Moo</a> (+ <a href="https://metacpan.org/module/Sub::Quote">Sub::Quote</a>), <a href="https://metacpan.org/module/MooX::Types::MooseLike">MooX::Types::MooseLike</a>, read-only attributes, documentation, <a href="https://metacpan.org/module/Dist::Zilla">Dist::Zilla</a> and so on.</p>

<p>It's on <a href="https://github.com/R3VoLuT1OneR/Net-Icecast2">Github</a> to hack on, and I assure you he is very cooperative. Feel free to help out, suggest improvements or offer any criticism.</p>]]>
        
    </content>
</entry>

<entry>
    <title>no ident specified when using Log::Dispatchouli (MooseX::Role::Loggable)</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/11/no-ident-specified-when-using-logdispatchouli-moosexroleloggable.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.4015</id>

    <published>2012-11-04T08:21:36Z</published>
    <updated>2012-11-04T08:42:18Z</updated>

    <summary>Sometimes when working with the lovely MooseX::Role::Loggable you might encounter the following fatal error: no ident specified when using Log::Dispatchouli at Loggable.pm line 117. I keep running into this and resolving this each time without remembering what this means, so...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>Sometimes when working with the lovely <a href="https://metacpan.org/module/MooseX::Role::Loggable">MooseX::Role::Loggable</a> you might encounter the following fatal error:</p>

<pre>no ident specified when using Log::Dispatchouli at Loggable.pm line 117.</pre>

<p>I keep running into this and resolving this each time without remembering what this means, so I keep having to debug it all over again. While I've documented this issue in the new version of MooseX::Role::Loggable, I'd like to explain it here as well.</p>]]>
        <![CDATA[<p>When using lazy builders, not <a href="https://metacpan.org/module/Moo">Moo</a> nor <a href="https://metacpan.org/module/Moose">Moose</a> promise an order of attribute inflation. That means that some attributes might exist before others.</p>

<p><a href="https://metacpan.org/module/MooseX::Role::Loggable">MooseX::Role::Loggable</a> adds a lazy attribute for <a href="https://metacpan.org/module/Log::Dispatchouli">Log::Dispatchouli</a>. If you don't call any logging method, you will not pay for the extra of Log::Dispatchouli (except the "use" statement for loading it). That attribute depends on other attributes which aren't lazy, but still might get inflated only <strong>after</strong> whatever attribute whose builder calls a logging method. Wait, let me rephrase!</p>

<p>You have a <code>db</code> attribute which has a builder that connects to the database. You add a <code>log_debug</code> method before it just so you can debug when the database is being connected. It looks like this:</p>

<pre>
has db => (
    is      => 'ro',
    builder => '_build_db',
);

<p>sub _build_db {<br />
    my $self = shift;<br />
    $self->log_debug('Connecting to DB');<br />
    ...<br />
}<br />
</pre></p>

<p>You call <code>log_debug</code> which calls the builder for the logger object, which now depends on the <code>ident</code> attribute, which... oh my, it hasn't been inflated yet. Damn!</p>

<p>The solution is simple: you make your attribute lazy, and then call for its inflation right after compilation phase, in the <code>BUILD</code> method.</p>

<pre>
has db => (
    is      => 'ro',
    lazy    => 1,
    builder => '_build_db',
);

<p>sub BUILD {<br />
    my $self = shift;<br />
    $self->db;<br />
}<br />
</pre></p>

<p>That will make sure that all non-lazy attributes are built before your <code>db</code> builder is run. Viola!</p>

<p>Hope this helps anyone who stumbles upon this. :)</p>]]>
    </content>
</entry>

<entry>
    <title>Domain-based session affinity/persistency</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/10/domain-based-session-affinitypersistency.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.3988</id>

    <published>2012-10-24T15:41:58Z</published>
    <updated>2012-10-24T16:42:34Z</updated>

    <summary>So, here is another pretty cool feature I&apos;ve implemented. It might interest you if you use multiple domains with reverse proxies. I was recently asked to add to Perlbal::Plugin::SessionAffinity the ability to allow consistent session affinity per domain. Hell, it&apos;s...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>So, here is another pretty cool feature I've implemented. It might interest you if you use multiple domains with reverse proxies.</p>

<p>I was recently asked to add to <a href="https://metacpan.org/module/Perlbal::Plugin::SessionAffinity">Perlbal::Plugin::SessionAffinity</a> the ability to allow consistent session affinity <strong>per domain</strong>. Hell, it's a paid feature so I took a look at it.</p>

<p>The idea is that if you have a lot of domains and you use <a href="https://metacpan.org/module/Perlbal::Plugin::SessionAffinity">Perlbal::Plugin::SessionAffinity</a> in your Perlbal reverse proxy, you might get a fragmented cache because each user will reach a different (yet consistent) backend, regardless of the domain they requested. When someone has more than 300 domains behind the same reverse proxies (and let me tell you, some people actually do), this fragmented cache reduces efficiency.</p>

<p>So, now <a href="https://metacpan.org/module/Perlbal::Plugin::SessionAffinity">Perlbal::Plugin::SessionAffinity</a> has a domain mode (which can be triggered by the <em>affinity_use_domain</em> configuration option) which returns a fixed backend for every client based on the requested domain. If the backend no longer exists (such as if, for instance, you removed it live from the pool), it will return a different backend - so you can still play with Perlbal live and it will not hurt the SessionAffinity module.</p>

<p>My client seems to have improved cache performance using this feature so far.</p>

<p>If you're using <a href="https://metacpan.org/module/Perlbal::Plugin::SessionAffinity">Perlbal::Plugin::SessionAffinity</a> and find it useful, drop me a line. If you're using this feature, I'd be happy to get any feedback.</p>]]>
        
    </content>
</entry>

<entry>
    <title>Counter-productive over time</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/10/counter-productive-over-time.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.3953</id>

    <published>2012-10-14T15:06:55Z</published>
    <updated>2012-10-14T16:32:37Z</updated>

    <summary>Ovid wrote a post recently on an unexpected result of Mojolicious&apos; &quot;no dependency&quot; policy. I won&apos;t go into the horror stories of people getting yelled at for saying Mojo doesn&apos;t support dependencies. Instead, I&apos;ll give my opinion on the concept...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>Ovid wrote a post recently on an <a href="http://blogs.perl.org/users/ovid/2012/10/mojolicious-an-unexpected-result.html">unexpected result of Mojolicious</a>' "no dependency" policy.</p>

<p>I won't go into the horror stories of people getting yelled at for saying Mojo doesn't support dependencies. Instead, I'll give my opinion on the concept of no dependency, and you could decide for yourself if it relates to Mojolicious or not. I honestly don't care. Obviously, this is not a "don't use Mojolicious" post. In fact, I think it's a cool framework and you should try it out. This post is about my general opinion on the "no dependency" idea. Mojolicious is an example, DBI is another, and there are definitely others (Moose, anyone)?</p>

<p>The whole "NO DEPENDENCY HEAVEN!11" approach to me seems like the PHP "we embedded the code in your HTML!11" approach. Basically, doing something that tries to handle the current situation but in a way that actually ends up counter-productive when technology advances.</p>

<p>Back in the day, web code printed out HTML code. That was horrible. CGI.pm tried to alleviate it by suggesting using functions instead of hardcoded HTML tags. It wasn't much better. Then PHP came along and said "hey, let's just embed the engine code inside the design code!" - everyone was happy. Then we realized HTML coding is actually outside the scope of engine coding (and vice versa), so they were separated. We created templates and had engine code render them using variables. Neat! But now PHP is actually an HTML document that only opens a PHP tag, that runs code that opens a different HTML document, which is an HTML template, and renders it to HTML. That's how <strong>all</strong> PHP applications are. Suddenly it ain't cool no more. Suddenly it's stupid.</p>

<p>The "no deps" camp (whether in a web framework or elsewhere) tries to handle a similar problem (which is actually temporary, and constrained by technology and willingness), which is the ability to include additional code. It's hard to change willingness (a point which Ovid expresses eloquently), but technology is more manageable. Including dependencies is no longer a hassle: you have local::lib, FatPacker, Carton, cpanminus, perlbrew and Plack. Nowadays, including additional code is actually <strong>very</strong> easy. In fact, some technologies (such as cpanminus, perlbrew and local::lib) made it extremely easy to install new code instead of bundling it. But hey, you can do both.</p>

<p>Mojolicious is one of the few projects that have such a skilled core team (and lead developer) that they actually <em>can</em> rewrite the entire core, including any required dependency from scratch, and do a damn good job. Unfortunately, this is not the case with most other developers. In fact, even very skilled developers (and there are a <strong>ton</strong> in the Perl community) prefer not to spend their time rewriting something that is already (possibly, plausibly, probably) well-written, even if they can do an incredible job at it.</p>

<p>This lays the beginning to the consequence Ovid mentions: people are learning from the "zero-dependency" concept to be zero-dependent. They actually start to abhor dependencies. I've seen people coming from that camp try to rewrite DBI. Yes, I really did see it. It was horrible and expectedly it failed.</p>

<p>So what does zero dependency really means? To me, it means you either don't support a lot of features, or have numerous possible bugs, or have rewritten a lot of things, or you don't know how to bundle your stuff, or don't know how to setup Pinto (or you don't understand the reasoning for it), or you don't understand the idea of reusability, or that you're incredibly arrogant thinking you can do better than everyone (and frankly, a few can), or... well, a lot of things which are generally not good practice, by any fair standard.</p>

<p>I honestly don't intend to work on projects that require me to use zero dependencies no matter what. It's a serious - in a term Ovid proliferated - code smell.</p>

<p>Remember, the excuses of "I don't have permissions to install new modules" or "I can only upload stuff here" are no longer relevant since we have tools to bundle stuff, pack them, install them locally and more. Those situations are no longer a problem.</p>

<p>In short: with time, technology changes, and we should have an approach that isn't locked on a certain approach that might change as technology advances.</p>]]>
        
    </content>
</entry>

<entry>
    <title>Yanick Champoux joins Dancer core team</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/09/yanick-champoux-joins-dancer-core-team.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.3879</id>

    <published>2012-09-24T22:01:50Z</published>
    <updated>2012-09-24T22:03:29Z</updated>

    <summary>I&apos;m pleased and excited to announce that Yanick Champoux has joined the Dancer core team....</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
        <category term="Dancer" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Perl" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>I'm pleased and excited to announce that Yanick Champoux has joined the Dancer core team.</p>]]>
        <![CDATA[<p>We've all been lucky, both in the Perl community and the Dancer community, to enjoy the fruits of Yanick's labor, whether its in his numerous contributions to Perl modules (and Perl core) but also for his humorous and insightful blog posts. And yes, he is also that charming in person!</p>

<p>Yanick is in charge of some big changes in Dancer (such as the megasplat feature) and we're honored to have Yanick on the team and know it will help propel Dancer - and mainly Dancer 2 - forward.</p>

<p>Welcome!</p>]]>
    </content>
</entry>

<entry>
    <title>Perl interface to LDTP is gaining traction</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/09/perl-on-ldtp-is-gaining-traction.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.3859</id>

    <published>2012-09-21T16:02:22Z</published>
    <updated>2012-09-21T16:23:39Z</updated>

    <summary>I&apos;ve written about the new Perl interface to the LDTP (Linux Desktop Testing Project) testing library that I had written. It already garnished some interest from people on Github. We&apos;ve had some progress on that front you might be interested...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
        <category term="Perl" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="ldtp" label="LDTP" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>I've written about <a href="http://blogs.perl.org/users/sawyer_x/2012/09/perl-interface-to-ldtp-testing-library.html">the new Perl interface</a> to the <a href="http://ldtp.freedesktop.org/wiki">LDTP (Linux Desktop Testing Project) testing library</a> that I had written. It already garnished some interest from people on <a href="https://github.com/xsawyerx/ldtp">Github</a>. We've had some progress on that front you might be interested in. Also, we still need your help! :)</p>]]>
        <![CDATA[<p>Since the publishing of that blog post, I had been contacted by Nagappan Alagappan, the author and maintainer of LDTP. He offered some insight on LDTP and suggested adding the Perl interface to the <a href="https://github.com/ldtp/ldtp2">LDTP Github project repository</a> as well. Beyond the issue of code duplication (which can easily be handled by documentation and versioning), I want to emphasize what this really means.</p>

<p>Being contacted by and working along with the LDTP community actually means that we were able to get outside the echo chamber of the Perl community. We got out there, we were noticed, and we were invited to participate in the big world with the other kids. It's being invited and welcomed to the big table, adjacent to our friends-only table.</p>

<p>While we ask often "why don't people notice how cool Perl is?", we should also be focusing a bit on "how can we work with people who don't do Perl and have Perl participate in the bigger technological realm?". This is how we can do it. This is why I was both excited and delighted by Nagappan's request.</p>

<p>Your help necessary:<br />
If you want Perl to be invited to more tables, if you want more of the outside world to see Perl under the spotlight, if you want to show that Perl is not just able, but actually <strong>does things</strong>, you can help us out with finishing the LDTP interface! Code, tests, documentation, examples - all very useful.</p>

<p>Remember, I'm giving away the commit bits for free for the rest of the year. Great deal, buy now!</p>]]>
    </content>
</entry>

<entry>
    <title>Perl interface to LDTP testing library</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/09/perl-interface-to-ldtp-testing-library.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.3841</id>

    <published>2012-09-17T20:58:15Z</published>
    <updated>2012-09-18T06:56:00Z</updated>

    <summary>Gabor Szabo realized that it&apos;s very easy to dare me to do things and then making them available for Perl. I&apos;m somewhat like Marty in Back to the Future - &quot;I am not chicken!&quot; So, now we have LDTP. However,...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
        <category term="Code" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Perl" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p><a href="http://szabgab.com/">Gabor Szabo</a> realized that it's very easy to dare me to do things and then making them available for Perl. I'm somewhat like Marty in Back to the Future - "I am <em>not</em> chicken!"</p>

<p>So, now we have LDTP. However, it needs your help. What is LDTP you ask? Good question!</p>]]>
        <![CDATA[<p><a href="http://ldtp.freedesktop.org/wiki">LDTP (Linux Desktop Testing Project)</a> is a library that allows you to easily write tests for GUI applications. This is tremendously useful for us in order to test applications like Padre. However, there was no Perl interface for it... until now.</p>

<p>I have written and uploaded an implementation of the majority of <a href="https://github.com/xsawyerx/ldtp">LDTP on my Github</a> account.</p>

<p>Why did I not release to CPAN yet? It's still missing three major issues:<br />
1. Finishing implementation for the few functions still missing. For some there is no reference implementation in other languages and this needs some researching.<br />
2. Writing tests and testing to see that the code actually works. I've done neither of these.<br />
3. There is no documentation at all for the module I wrote.</p>

<p>So this is where <strong>you</strong> come in. I'm willing to provide free unlimited commit bits to anyone that cares to add/change/document/test anything in the project. Hit me up with a request, get the commit bit, ask questions and help out in any way you can.</p>

<p>Please, help us see this through!</p>]]>
    </content>
</entry>

<entry>
    <title>This is not tolerated</title>
    <link rel="alternate" type="text/html" href="http://blogs.perl.org/users/sawyer_x/2012/08/this-is-not-tolerated.html" />
    <id>tag:blogs.perl.org,2012:/users/sawyer_x//87.3771</id>

    <published>2012-08-31T19:46:35Z</published>
    <updated>2012-08-31T22:11:14Z</updated>

    <summary>There had been several posts recently about disgusting sexist idiotic behavior on PerlMonks. Most people know my opinion on these issues very well, but I don&apos;t think that&apos;s good enough. I think we need to actually bring it up and...</summary>
    <author>
        <name>Sawyer X</name>
        
    </author>
    
        <category term="Rant" scheme="http://www.sixapart.com/ns/types#category" />
    
    
    <content type="html" xml:lang="en" xml:base="http://blogs.perl.org/users/sawyer_x/">
        <![CDATA[<p>There had been <a href="http://blogs.perl.org/users/joe_mcmahon1/2012/08/why-im-considering-dropping-perlmonks.html">several</a> <a href="http://www.modernperlbooks.com/mt/2012/08/you-dont-get-to-choose-how-other-people-feel.html">posts</a> <a href="http://blogs.perl.org/users/tinita/2012/08/to-be-or-not-to-be-part-of-the-community.html">recently</a> <a href="http://blogs.perl.org/users/lichtkind/2012/08/to-say-schwern-is-simply-too-simple.html">about</a> <a href="http://www.perlmonks.org/?node_id=989181">disgusting sexist idiotic behavior</a> on <a href="http://www.perlmonks.org/">PerlMonks</a>. Most people know my opinion on these issues very well, but I don't think that's good enough. I think we need to actually bring it up and discuss it. I want to thank all the people who wrote about it and specifically <a href="http://blogs.perl.org/users/joe_mcmahon1/2012/08/why-im-considering-dropping-perlmonks.html">Joe McMahon</a> who both spoke of it on blogs.perl.org and on Perlmonks <a href="http://perlmonks.org/?node_id=989879">here</a>. No, this is not to be taken lightly. And no, I will not shut up about this. And yes, my post is probably gonna be long. I'm sorry, but I need to put it out there.</p>

<p><strong>First, how I feel about it:</strong> It's sexist, it's creepy, it's horrible. If such behavior is accepted in PerlMonks, I would understand Joe if he were to leave over this. Why? Because <strong>we are our community</strong>, and by "we" I'm including women as well. By allowing such behavior, we are separating ourselves from a broad "we" to a limited "us" (males) vs. "them" (females, and those who "can't take a joke"). You're basically drawing a line saying "sorry, you girls (and people who don't get how hilarious boob jokes are) are excluded from our community". You do not live in your own little bubble with your friends who chuckle at the word "boob" in the calculator. You're in a community with other people (who are apparently more sensitive, considerate, sexually mature, and mentally developed than you) who do not deserve to be ostracized because of you.</p>

<p><strong>Cut it out with the socially inept bullshit:</strong> many guys (read: geeks) are socially inept. Surprise, women also. The fact that it's hard for you to understand people in a social capacity does not exclude you from A. understanding that boob jokes are disgustingly sexist and objectify women, and B. being considerate enough to actually pause and say "ya know what? I honestly didn't mean to hurt anyone. I apologize." Don't give me this "we don't know how to talk to girls" bullshit. I don't know how to talk to girls either. This doesn't exclude me from basic common understanding of both hurting someone or at least at the very least accepting responsibility when I hurt someone, instead of a weak cop-out.</p>

<p><strong>"<em>You just can't take a joke</em>":</strong> it's not about good humor vs. bad humor. If you know me in person, you know I have a horrible sense of humor in the realm of political correctness. You know what's the difference? I don't consider my humor a reflection of society. My off-color humor is never to reflect how I think of society and people. That joke actually said that big-breasted women are better. Can you objectify and demean anyone more than that? Do you actually see <strong>no</strong> problem with that?</p>

<p><strong><em>So I can't make sexual jokes now?</em></strong>: You might. However,  You are part of a community with people you do not necessarily know, and you should understand the forum you're engaged in. This means that even sexual jokes that are not demeaning or hurt feelings might ostracize some people. You need to be *gasp* <strong>considerate of others</strong>. Perhaps after the meeting, when you all go out to the pub, you could tell some of these jokes and people (including the women) will laugh with you. Perhaps not. If not, you'll know that you'll have to save these jokes for later.</p>

<p><strong>Is sex a forbidden topic?</strong> Sex is not a forbidden topic. Adults actually talk about sex frequently, when they feel it's fitting and when they feel comfortable. Sexualizing software, demeaning women to a set of breasts and prioritizing their importance by size, that's not "talking about sex". That's disgusting behavior. </p>

<p>Remember, we compose who our community is, and "we" includes more people than you'd probably imagine. It includes different races, different colors, different creeds (or the lack thereof), different genders (or the lack thereof) and even different types of hairdos (or, again, the lack thereof). It's not a bunch of people who make it difficult for the community to joke about stupid stuff, it's <strong>the community itself</strong> complaining. And what this community is telling you, and is telling us, is that it will <strong>not</strong> accept such behavior. I'm thankful that this is my community.</p>

<p>UPDATE: Of course I made a typo there. Fixed.</p>]]>
        
    </content>
</entry>

</feed>
