skoop.dev

  • About
  • @skoop@phpc.social
  • PHPNW 13

    October 7, 2013
    community, conferences, php, phpnw, phpnw13

    Who’s this? Oh wait, it’s me. I’ve finally taken the time to fix my blog. This means my archive of old blogposts is back, although unfortunately the comments are not. I took some time yesterday at the most excellent PHPNW 2013 conference to finally get my new blogging software (Octopress) up and running, together with Disqus comments. But really, this is not what I wanted to write about! What I wanted to write about was the PHPNW 2013 conference!

    On Thursday afternoon, Ingewikkeld took off from Schiphol airport to fly to Manchester, where we were picked up by Jenny Wong of the PHPNW crew. After being dropped off at the hotel, we checked in, found our rooms, freshened up to continue onwards to the tutorial speakers dinner. Both Mike van Riel and myself were scheduled to be delivering a tutorial on Friday, so a good dinner was quite welcome. The conference made sure we felt welcome, and we had an awesome dinner.

    Friday morning, time for the tutorial day! I delivered my “Build your first Symfony2 application“, covering the basics of building an application using Symfony2. To my surprise, none of the delegates had any technical issues (which are often the problems that take up a lot of time), so by the time we had a coffee break halfway along, we’d already run through all of the basics: Installation, configuration, controllers, Doctrine basics, Twig basics. This allowed us to move onwards to more advanced topics such as the slightly more advanced Doctrine stuff, the service container etc. I was quite impressed by the amount of material we were able to cover.

    I took the afternoon “off” to finish my slides for the talk I was scheduled for on friday afternoon. Also, as I got talked into doing a 20-minute talk in the unconference by Kat right in the first uncon slot in the morning, I started thinking of topics to cover for that. After finishing the slides and talking to a lot of people, we had speaker’s dinner. Again, a good time was had. After the hackathon, where we hacked a bit on several different open source projects (with me spending some time on ProTalk), the night was ended with a game of Cards Against Humanity, a game I first got to know at the WhiskyWeb conference which by now seems to be required playing at every PHP conference.

    Saturday started with a very exciting keynote by Ivo Jansch and Lorna Mitchell. Exciting because the content was really good, but also because Ivo and Lorna were split out over two rooms with a live video- and audiolink. The keynote was an excellent overview of different ways to become a better developer, and Ivo and Lorna launched a book on the same topic.

    After the keynote, I made my way to the uncon room where I spoke about “How to get the most out of a developer conference”, a brand new talk (without slides so far, so I can’t link to the slides). In 20 minutes, I gave the delegates an overview of things to do while at a developer conference. After I was done, I sat in on the other 20-minute talk in the first uncon timeslot, which was “Errors, Exceptions and Logging” by James Titcumb. James was a first-time conference speaker with this talk, but he could as well have been speaking for the tenth time. His talk was an interesting overview of error handling and logging, and some stuff (like the logging architecture he described) could make a full talk on it’s own. I hope to see that at some point.

    At the end of the day, in the last slot, I delivered my talk “How Cilex and Silex became the glue for a media transcoding application“. I was not completely satisfied with this talk, but the feedback I got was still pretty good. I do have some good pointers now for improving this talk before I do it again.

    Spread out over Saturday, I got to see some excellent talks! Great content especially of Chris Saylor (on event-driven programming), where he talked about how to do event-driven development, why it is cool, but also some of the pitfalls. The uncon was also quite nice, with even some Ticket to Ride during the lunchbreak. The Saturday social event included some excellent food, nice drinks and excellent company. And again: Cards Against Humanity 😉

    On Sunday morning after doing out for a short run and getting some breakfast, it was time for the talk I had most anticipated, “Don’t be STUPID, grasp SOLID” by Anthony Ferrara. In this talk, Anthony delivered in his own very impressively good speaking style some important principles on object-oriented design and programming. A great talk for sure, and definately lived up to my expectations. I then took a short break, after which I went to see the keynote by Rowan Merewood. I think I’ve seen this keynote 3 or 4 times by now, but it is still a good reminder of some important topics of how to improve yourself or other developers.

    And with that the PHPNW Conference was closed off. After some closing remarks by big boss Jeremy Coates, we headed for a nice lunch, and then off to the airport back to Amsterdam.

    What a fantastic conference. The atmosphere, content, people, venue, everything is just right. I will definitely be going to PHPNW again next year.

  • Data migration with Doctrine2

    July 25, 2012
    data migration, Doctrine2, php, symfony, Symfony2

    The cause

    As it turns out, the cause of the problem is the fact that when you specify strategy=”AUTO” for your ID-field, Doctrine2 will ignore any existing ID you’ve set in the entity. It will generate one because, well, you’ve specified it should be doing this. And usually, this is correct behaviour, but with the migration of existing data, to retain correct relations etc, it is much easier to keep the old IDs.

    The solution

    The solution is easy and, as usual, I found it thanks to StackOverflow. In your migrationscript, for each of the entities you’re migrating, you just temporarily turn off the strategy: As soon as I had added the above snippet for all the entities I’m migrating, it kept the old IDs and migration all of a sudden went flawlessly.

    Update: The above method assumes you have a way of setting the ID in the entity, for instance a setId() method.

  • PHPNW12: You should be there, and someone can be there

    July 11, 2012
    conferences, free ticket, ingewikkeld, manchester, php, phpnw, phpnw12

    It all started last year: I decided I wanted to go to PHPNW even if I wasn’t accepted as a speaker. Being Dutch, I made sure to purchase my ticket for the conference during the blind bird period to save some money. But then I got accepted as a speaker. Part of the speaker package is a ticket to the conference, so I had this spare ticket.

    One option would be to get a refund. The PHPNW crew had no problem with this. But then I figured I could actually also try and do some good for the PHP community with the ticket. I’d spent the money already, why not use it for someone’s benefit.

    Giving back

    When I was just starting out with PHP, 15 years ago this year, I got so many help from the PHP community in my learning and understanding the language. Whether it was through blogposts, the documentation, IRC channels, even e-mails from people who reviewed the code of some stuff I open sourced and found security flaws, I got so much help. So I decided to try and help someone to learn as well.

    From my involvement with PHPBenelux, I knew Tobias Gies, who had been a volunteer at the PHPBenelux Conference and had been a great asset there. I knew Tobias is usually not in a position to get around to a lot of conferences, so I suggested he take my ticket, so he only had to arrange for travel and lodging. Tobias accepted, and he had an awesome time in Manchester. He actually had such a good time that he decided to attend PHPNW again this year.

    2012

    This year, the same thing happened: I purchased my blindbird ticket, but got accepted as a speaker. And again, I want to support someone who otherwise would not be able to attend the conference. This can be someone local to Manchester (or the UK), but could also be someone internationally. I will only raffle a ticket, so whoever wins has to be able to cover travel and lodging expenses.

    Where last year I contacted someone I already knew, this year, I’m open to anyone! However, I don’t want people applying for the ticket themselves. So what I want to do is that you can nominate someone to win the ticket. I’m mostly looking at members of the PHPNW usergroup here, but also to students who want to nominate fellow students, people who want to nominate a colleague, or friends. International submissions are welcome, but you have to be certain that the person you submit for will be able to cover travel and lodging expenses!

    How to nominate?

    Nominating someone is easy. Send an e-mail to phpnw12@ingewikkeld.net, listing the following information:

    • Name of the person you’re nominating
    • E-mailaddress of the person you’re nominating
    • The reason why I should pick this person

    Out of all entries made before August 15th, I will pick someone based on the reasons submitted in the e-mail. The winner will be contacted before the end of August, and announced as soon as the winner has confirmed (s)he will be able to attend.

  • Dutch PHP TestFest big success

    June 25, 2012
    amsterdamphp, pfz.nl, php, qa, testfest

    At the start of the day the group was split up into three smaller groups. Together with Felix De Vliegher the first group sat down to work on the Gearman extension. Together with Derick Rethans the second group started working on tests for the MongoDB extension, and the rest of the group joined Rafael Dohms to write tests for the core of PHP. In each group, the mentor started with an introduction and some pointers on how to write tests, and then everyone started work.

    This morning, as we started checking the results of the TestFest, we were amazed at the results. One of the reasons for this was that some people actually continued writing tests when they got home, which is awesome! The total amount of tests so far is 54 tests, with a clear focus on the core of PHP (over 40 tests were written by that group!)

    It was amazing to see so much interest in writing tests for PHP, and even better to see the result of this day of testing. Thanks everyone for your work!

    Disclaimer: This post was posted before in Dutch at PFZ.nl

  • Boston PHP community, I need your help!

    May 8, 2012
    conferences, northeastphp, php, symfony

    Usually this means I have to cancel my speaking at the conference, but I would really love to be part of this conference. So, I’m looking for one or more companies in the Boston area that are interested in hiring me (or possibly me and Joshua Thijssen, my business partner in Techademy) for training, consulting or a couple of days of development. The way I figure it, if I can sell two or three days worth of work in the Boston area, that will fund my trip and hotel for the NorthEast PHP conference.

    Another option of course would be a company that is looking for some community cred in the NorthEast area to sponsor me (and Josh?) to come over. If we can get at least part of the flight covered by a sponsor, that will already help us big time. And yes, I will give you credit during my talk as well on twitter, facebook and my blog. How cool is that?

    If you’re interested in hiring me (and Josh?), please get in touch! Please, dear NorthEast PHP community, help me fly over to Boston and meet you all!

  • GlobIterator: Easy access to specific files

    April 16, 2012
    directoryiterator, fileiterator, globiterator, iterators, php, spl

    GlobIterator exists since PHP5.3, and basically allows to iterator over anything glob()able. So instead of having to write my own custom FilterIterator and pass the DirectoryIterator for my directory to that FilterIterator, I can simple instantiate GlobIterator and pass the pattern that I need to it:

    $watchDir = new \GlobIterator($config['incomingPath'].'/*.xml');

    Now I can foreach over $watchDir and do whatever I need to do (in this case parse XML) with only a couple of lines of code! WIN!

    Update: Davey rightfully asked “why not use glob() in the first place?”. To clarify: I am using GlobIterator because I want to have SplFileInfo objects instead of just plain filenames. I need some of the meta info SplFileInfo offers.

  • Setting millisecond-timeout with cURL

    April 13, 2012
    curl, libcurl, php, timeout

    So how did I found out about this? Thanks to Steve Kamerman, who took the time to comment to the PHP documentation. It turns out this issue is caused by the way libcurl behaves on linux and unix systems, where a SIGALRM is raised during the name resolution that is being caught by libcurl as a timeout alarm. Because of this, the request times out immediately instead of after the actual timeout.

    The solution is to tell curl to ignore signals alltogether. This is not a perfect solution of course, because you’re now suppressing something that can be useful in other situations, but in this case we decided the timeouts to be too important for the software to not use timeouts. So now it looks like this:

    $curl = curl_init();
    curl_setopt($curl, CURLOPT_URL, $url);
    curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($curl, CURLOPT_TIMEOUT_MS, 250);
    curl_setopt($curl, CURLOPT_NOSIGNAL, 1);
    

    It now works like a charm!

  • Using custom namespaces with (C/S)ilex and Composer

    April 11, 2012
    autoloading, cilex, composer, PSR-0, silex

    Aside from installing dependencies and creating an autoloader for those dependencies, Composer can also be the autoloader for your own custom code. Obviously, it’s a matter of reading the F***** documentation, and as soon as Jordi told me Composer could actually do this, I quickly had stuff set up. All I needed to do was add an autoload entry to my composer.json file:

    "autoload": {
        "psr-0": {"Foo": "lib"}
    }
    

    After that, you need to run composer.phar install to generate the new autoloader, and I’m all set. I can now load all libraries as long as they adhere to the PSR-0 naming standard (because I specified psr-0). If you don’t use PSR-0, you could actually also use a classmap, as discussed in the documentation.

  • Using git-svn with Symfony2’s deps installer

    April 3, 2012
    deps, filter-branch, git, Symfony2

    Googling around a bit, I found the solution which I’m going to share here with you. It involves a couple of steps.

    • Remove the .git directories from the external bundles
    • Run git filter-branch –index-filter ‘git rm -r -f –cached –ignore-unmatch vendor/bundles/Liip/MonitorBundle’ -f on each of the external bundle directories where you removed the .git directory. This command needs to be run from the root of your git project!
    • Git svn dcommit your changes again

    Now it should all work again.

    Some links I used while researching this are:

    • SO: git svn dcommit not work
    • A quick trip to the panic room
    • Detach many subdirectories into a new, separate Git repository
    • How do I enable shell options in git?
  • On conferences, women and sponsors

    March 2, 2012
    conferences, inclusivity, php, tech, women

    Let me start off with quoting a tweet I just posted:

    I find it interesting that people that claim to care about “inclusivity” say one should exclude people to attain that goal

    Let me get one thing straight: I don’t care *at all* about porn. I am not a consumer of adult entertainment. I also care *a lot* about getting more women into technology as I feel women are highly underrepresented in “our” field of work. So yes, I am all for promoting technology to women. However, I have a really hard time with the bitching (pardon my french) about what is wrong with tech conferences and such.

    What you’re saying is that to include one group of people, conference organizers need to exclude another group of people. Isn’t that discrimination against the other group of people. The fact that they work in a business that you feel is wrong, does not mean they are evil people. I can highly understand the choice of Eric Pickup as a keynote speaker. Not because he works in the adult entertainment business, but because from a technological point of view his challenges are really interesting, and the solutions they implemented may benefit any attendees, male or female. It may well improve their skills for their next project. Now, I did not attend his keynote, so this is pure assumption, but I assume Eric did not actually include graphical content in his slides or talk. I assume that he kept to the technical challenges and solutions. If he did this, then there is nothing offensive to anyone. It is an interesting technical presentation.

    Similarly, for having those companies as sponsors: If I look at the ConFoo website, I see nothing offensive. The sponsors did not add offensive banners/logo’s to the site, and if I click on the links I don’t see any immediately offensive material on either website. The only reason you might be offended is the fact that you *know* they are in the adult entertainment business. So I wonder: If you know they are in that business, then why not just ignore them. Why not just stay away from their booth (if they have one), not click on the links on the ConFoo website?

    I’ve attended ConFoo once, and the ConFoo crew did not come across to me as stupid people that would not care about anything. They came across as really smart people that do not want to offend people. I am pretty convinced that if any sponsor would try to add anything offensive into the goodie bag, they would object to that and block it.

    Again: I *want* women to do well in technology and do anything I can to support this, including supporting aspiring female speakers in getting spots at conferences. However, I do this mostly because I am confident that they have something interesting to say and *not* because they are female. I understand you would not feel welcome when you would get adult imagery thrown into your face as soon as you hit the conference website or open your goodie bag. I would object to that as well. But I see nothing wrong with including those companies in the sponsorlist or accepting a speaker from that business, as long as they stays within certain limits of decency in their outings at the conference.

Previous Page
1 … 14 15 16 17 18 … 61
Next Page

skoop.dev

  • Bandcamp
  • Mastodon
  • Bandcamp