Paul M. Jones

Don't listen to the crowd, they say "jump."

Solar 0.0.2 released

It used to be called Hive; now it's Solar, the "Simple Object Library and Application Repository" for PHP5. This is only a development release. You can pick up the PEAR tarball here:

http://solarphp.com/Solar-0.0.2.tgz

No real documentation yet, but you can read the auto-generated API reference here:

http://solarphp.com/api/

Next set of tasks is to get the Solar_Cell_Bugs component working properly, and I can write up a quick app to do bug tracking. Also need a mailing list, and need to set up YaWiki installation for real documentation (although Solar will have a wiki component of its own, and at that point it can be self-hosted / autonomous / internally-dependent / eat its own dog food / whatever).

Revision control is going through Subversion now instead of CVS, provided by the kind folks at TextDrive, who are the web hosts for solarphp.com as well. For $12/month, it's a sweet deal; my thanks to Ryan King for pointing them out.


Battlestar Galactica

When I heard lat year that Sci-Fi channel was re-making Battlestar Galactica, my reaction was "eh." The original was a lot of fun for a 10-year old, but seeing re-runs of it, as an adult, were not very exciting.

Flipping through TV channels a few weeks ago, I happened upon an over-the-air broadcast on NBC of last year's 3-hours pilot episode. At first, I didn't recognize it; all I saw was a space panorama and some really good camera work, zooming in from a distance onto a far battle scene. It was an amazing shot, communicating the vast distances of space and the dynamic of the dogfight at the same time. Although I had stumbled across it by accident and the story was already half over, I was hooked immediately.

This new Battlestar Galactica is a very, very smart piece of work in too many ways to detail in one sitting. I cannot begin to describe how exceptionally well-done this series is: the characters are well developed and have distinct and conflicting personalities and motivations, the effects are amazing, the physics is really quite decent, the backstory is believable, and the bad guys have religion (really!).

Above all, the plotlines are not stupid; the writers assume you can figure things out yourself, and then hint you along so you can keep up. They don't use technical jargon and pseudo-science as deus ex machina (*cough*startrek*cough*). There are some great surprises, little touches that you would not have guessed but are funny and realistic and enjoyable.

Not to wax too enthusiastic (although I am very enthusiastic about this series now) but the effects are spectacular. The attention to detail is superb. To take one element, look at the Viper combat spacecraft. When a Viper is shooting out of a launch tube, you can see its counterweight-driver racing backwards beneath the track; while maneuvering, you see the attitude jets firing; and the maneuvering itself is three-dimensional -- it looks very like space combat should, with a full sphere of action, not just a plane, and arcs of fire, not just straight lines.

The camera work, even though a lot of it is CGI, is both believable and engrossing; you just cant take your eyes off it. The interior shots are shaky, as if it were a documentary. There are lots of little homages to other science fiction films in the set work; in particular, the interior design of the President's ship reminds me a great deal of the Pan-Am LEO shuttle from 2001. The first time I saw the blonde Cylon agent, all I could think of was Maria from Metropolis.

A friend of mine snagged the entire first season and passed it over to me last night. I have now lost all productivity as I watch "just one more epsiode". I watched two last night, and three this morning, ignoring homework, domestic duties, and programming. Get your hands on it as soon as you can, and then set aside a weekend to watch it (or five sequential evenings). It's just that good.


Shared Hosts with Subversion?

I want to use Subversion for the Solar project, not CVS, but I can't find a shared host that has it. I use pair.com for absolutely everything, but they won't let me run svnserve on a shared host (which is reasonable) and the Apache2 track is not an option for me.

Anybody know of a reliable web host that has Subversion installed for remote use?

(UPDATE 2005-02-17) I ended up going with TextDrive.


The Hive is dead. Long live Solar!

Inspiration struck this morning. I wanted to get across the idea that this library is essentially a collection of simple, straightforward objects that are all related to each other and share common development principles; in addition, it would come with common application pieces pre-built. An ant hive seemed a good metaphor to use in that case. But as we have learned, the name Hive is already taken, so that's out.

However, I think I have a good replacement name: the Simple Object Library and Application Repository for PHP, or Solar. It is short, highly descriptive, lends itself to a logo and a catchphrase, and is sufficiently specific that you know what it is without being so generic that it has no meaning by itself. And nobody else is using it. :-)

So the domains are registered, all that remains is to rename the class structures and re-commit to CVS.

UPDATE (2005-02-21): You can visit http://solarphp.com/ for more information; and, of course, check back on this blog periodically.


More Than One Hive

Robert Janeczek notes that his project, also called Hive, won an award in the Zend PHP5 coding contest last year. It's obvious he has first dibs on the name; it's also obvious that I didn't search hard enough for other PHP5 projects using that name.

So what to do now, seeing as I already went and bought the domain name "phphive.com"? :-(


Introducing: the Hive

The world may not feel the need for yet another class library, but after two years with PEAR, I sure do. My attempt to unify PEAR packages with a wrapper package (which I attempted with Yawp) is essentially a dead-end. While I like the mode of operation I have developed with Yawp and DB_Table and Savant, I do not think the PEAR project is open to incorporating such a mode.

With that in mind, I am introducing a new class library for PHP5: the Hive. You can download a PEAR package of it. While this is a 0.0.1 development release, I think you will find the work well fleshed out, with a current PhpDocumentor-generated API reference. End-user documentation will be forthcoming in the next few weeks.

A Bit About My Pear Background

What is it that developers love about PEAR? Look no further than this page, which was the result of a call-for-replies on the PEAR-DEV mailing list last year. Let me add to that list my own reasons why I started using PEAR classes.

In the beginning, there was only one thing that mattered to me: unified error handling. That was it, really. If a foreign object reported an error, I knew exactly how to check for it and what format it would be in; if I needed to report an error, I knew exactly how to format it. Thus, for all its flaws, PEAR_Error was the main reason I started using PEAR classes. Add to that the PEAR DB abstraction package, which was a great labor-saver. Finally, and I have come to love this more than anything else, the PEAR installer has turned into a work of genius under the stewardship of Greg Beaver.

But I have come to believe that PEAR is too much a mishmash; even with coding style standards, the class packages operate according to widely varying styles. In addition, it is far too difficult to add a new package that I find useful but is similar in purpose to an existing package (even if the principles of their operation are widely different). For example, see the acceptance of DB_Table in the face of serious opposition and only after patient months of lobbying, as well the rejection of Savant after a knock-down drag-out (to which rejection I contributed my own fair share).

In short, I find it much too hard to do anything new or different within PEAR that is not already part of PEAR doctrine; while this brings stability, it also brings a certain morbidity. (This is not to say I'm leaving PEAR; I'm not. I am just going to concentrate my new development efforts outside PEAR, not inside it.)

Foundational Principles Of The Hive

There is one essential principle behind the Hive: comprehensibility. Developers exploring the Hive should be able to comprehend the code quickly and easily, so they can see exactly what's going on and why. In short, I am tired of slogging through uncommented, undocumented, complex, obtuse code and packages, whether mine or someone else's.

The principle of comprehensibility gives rise to two corollaries:

  • Simplicity of code
  • Obsessive dedication to comments and documentation

These in turn mean that it should be easy to extend and customize code in the Hive, but that has yet to be borne out.

Some Technical Notes

The Hive adheres to PEAR coding style standards and its directory structure is similar to PEAR's.

Hive can exist with any other library set, including standalone libraries, PEAR, Horde, and so on; using the Hive does not mean you are limited to the Hive.

Hive comes with a shared-object aggregator and convenience method central class and some basic functional classes:

  • Hive_Cache for caching; both file and memcached are currently supported
  • Hive_Error for unified error handling
  • Hive_Sql for identical-operation database abstraction (will migrate to a PDO backend as PDO comes on-line)
  • Hive_Sql_Entity for representing data-type abstracted tables with automated validation and form-hints generation
  • Hive_User for user authentication and roles/groups (preferences and permissions will arrive later)
  • Hive_Valid for data validation

One major goal of the Hive is to provide shared application component backends that are not tied to any particular display mechanism. This is accomplished through Hive_Sql_Entity (the successor to DB_Table) and the Hive.conf.php configuration mechanism, along with the shared object instantiator Hive::shared (which is a successor to the Yawp::getObject technique). The initial set of application component objects will include a comment/trackback tool, a wiki page storage interface, and a blog entry storage interface.

Cliffhanger

(Not a conclusion. ;-) I'll be writing more about the Hive in weeks to come; with any luck, this will be in the form of documentation, as well as blogging about feedback, issues, ideas, and to-do items.

As always, I'm happy to hear feedback and see trackbacks.

Update (2005-03-08)

Somebody else is using the name "Hive" for a PHP5 project. I have adopted a new name for the project: Solar. You can search this blog for other Solar entries to learn more, or visit the Solar home page.


Text_Wiki 0.24.0 beta

I released a new version of Text_Wiki today composed of some bugfixes and functionality enhancements (all based on user requests, thanks everyone!).

The big deal is that Text_Wiki is "beta" now. Even though it doesn't have all the renderers I would like, the API has proven stable and extensible. The full change notes are:

* fixed Bug:2670 (incorrect css_new case in "wikilink" xhtml renderer)

* fixed Bug:2916 (parser for "code" does not set all attributes)

* implemented Request:2947 (more flexible way to handle wikilinks) -- the wikilink renderer now lets you specify a callback to determine if a page exists or not

* implemented Request:2917 (allow dot in interwiki regex parser)

* implemented Request:3162 (allow for additional punctuation in interwiki regex parser)

Text_Wiki is a PEAR package designed to parse wiki text into an intermediate format, and then render the parsed text into any supported output format (XHTML by default, but plain text and Latex are also supported, and RTF as well as other formats are expected in the future).


First Free Elections Ever in Iraq

Today, Iraqis get to vote. They were beaten, murdered, gassed, starved, raped, looted, and tyrannized by a dictator for fifty years, and by kings and tyrants before that for all time in memory. But today they get to vote.

Regardless of your short-term petty political bickering about Bush, he's the one who got this ball rolling. Today a people gets to choose its government, because America looked to its own interests, and found those interests to be the same as the Iraqi people: freedom.

A small minority wants to blow them up for voting; those in that minority has only violence and blood, not freedom, on their minds. That's not going to stop the vast majority who want freedom; they will vote, not in spite of, but because of the danger that minority represents.

It's a good day. Break out the cigars, and hail: "Democracy! Whiskey! Sexy!"


Savant 2.3.3 released

Savant version 2.3.3 is ready for download. The change notes are:

* the form plugin now defaults to null for "clear" and "float" on blocks; previous default settings would break surrounding CSS layout

* the form plugin now has added 'layout' setting; when false, no automatic layout is produced; default is true

* the form plugin now unquotes based on GPC -or- runtime magic quotes (becuase values may be coming directly from database)

* basic compiler now uses regular expressions to parse templates

* basic compiler has 'strict' flag to restrict the PHP used in a compiled template, but it's not yet fully operational (chokes on some valid variable code, waiting for fixes in PHPCodeAnalyzer)


Complication Is A Sign Of Muddled Thought

From gapingvoid:

"Having digested shedloads of advertising lingo over the last decade, I'm suddenly finding that the answers that really resonate with me are getting simpler and simpler. Complication is a sign of weakness. Complication is a sign of muddled thought."