Weblog Navigation
First Previous Index Next Last
PHP Is Lame (Sunday, May 27th, 2007)

So here's an example of PHP's lameness. The server that hosts pear.php.net and pecl.php.net went down today; as of this writing, several hours later, it's still down. That's OK. These things happen. That's not the lame part.

There's a mirror of pear.php.net at us.pear.php.net, so all you have to do is tell pear to use the mirror. It even tells you how to do this when you go to http://us.pear.php.net/, which is quite helpful. When you run this command, it says config-set succeeded to let you know it worked. So far so good. There's just one tiny little bug: pear doesn't actually use this configuration setting. It does get saved to your ~/.pearrc file (so the success message is accurate), but pear config-show reveals that this setting is ignored.

That's OK. It's a minor bug (albeit one that should have been found and fixed long before now). I'm sure somebody will track it down and fixit soon. In the mean time, we can work around it by adding pear.php.net and the IP address of the mirror site to /etc/hosts, which tricks the system into using the mirror site anyway.

Except that we still can't use pear. Why not? Because for some reason beyond my comprehension, pear also needs to fetch something from pecl.php.net (which is also down, since it's the same server), and this site is apparently hard-coded in pear - there is no configuration option to use a mirror. That's not really a problem either though, because - are you ready for this? - there is no mirror site. That's right, there is no mirror of pecl.php.net anywhere, and pear won't work without it.

Naturally, CPAN doesn't have these problems.

Weblog Navigation
First Previous Index Next Last