Phergie 2.0.3 Released
My profound apologies for the even longer delay on this release — believe me, I felt it when putting together the changelog for it — but I’m elated to announce that Phergie 2.0.3 is now available. You can read about the many bug fixes and exciting new additions in this release on the Changelog page. With this release, we’ll be attempting to replace the dated Phergie 1.x installation running on the Freenode network with this new 2.x release. Once again, our thanks go out to all of our users and contributors for their help in making the Phergie project a continued success!
Category: Releases 4 comments »


August 19th, 2010 at 1:53 am
The first line of the changelog drew my attention. I’ve been working with PHP-IRC (@ phpbots.org) and I’ve also tried another framework called Joker — both of which allow hot-reloading of plugins by way of PHP’s eval() function. I know correlation doesn’t necessary mean causation, but with both of those frameworks I was unable to write to a UDP socket (which I need to communicate with a game server). When I tried to, the bot would always hang. I tried running the same code from a standalone PHP file, and it worked perfectly — so that leads me to believe that for some reason I can’t write to a socket from within eval().
So my question is, does the hot-reloading feature you’ve added use eval()? (Please tell me it doesn’t!)
August 19th, 2010 at 2:00 am
@Garrett While I can’t say whether your premise is correct or not, I unfortunately have to admit that hot reloading is accomplished by way of eval(). The class source is read in as a string, its name is altered (to avoid conflict if another version of the same class is already defined), and it’s passed through eval() to create the class before instantiating it and swapping out the old instance for the new.
January 6th, 2011 at 10:23 pm
The reason I was asking is that I’ve run into what seems to be a PHP bug — I can’t write to streams within an eval() — and I need to be able to do that somehow.
January 15th, 2011 at 2:40 am
I take that back — it seems to have been my own error. :)