?

Log in

No account? Create an account

Previous Entry | Next Entry

Dear young programmer,

Thank you for your contribution to open source. I have spent five hours learning your framework, which you have described as "a mature, flexible and robust object-oriented framework that leverages the power of Smarty". I found these qualities to be attractive, and was hoping that the process of learning the framework would pay off down the road in terms of shorter development times and more reliable sanitization of data.

Now, this is in the context of having, the day before, tried another programmer's framework, which very quickly became a baroque tangle of references and dereferences that would have been an absolute nightmare to debug, translated from portuguese into english, yet carrying all the idioms of that rich and noble language which I do not, in fact, speak.

But it put me in mind of language, and how one man's definition may not necessarily match another man's definition. For example:


  1. "Mature" does not simply mean old, with longstanding bugs, and out-of-date documentation that does not address the basic limitations of the framework.
  2. "Flexible" does not mean that there is only one way of sending an error message to the screen, and because of your reliance on a perverse use of sessions and caching, debugging requires a restart of the browser AND the server on every iteration.
  3. "Robust" does not mean that only one error message can be sent per CGI variable. Total.
  4. "Object-Oriented" does not mean that your objects are simply namespaces filled with functions.
  5. "Leverages" does not mean that it makes absolutely no use of Smarty syntax beyond its own specialized tags and at no time communicates the variables it has procured in sanitization back to the Smarty global handle.
  6. "The Power of Smarty" is, simply, that there is a one-to-one relationship between PHP associative and iterative arrays and the presentation on the screen of elements of HTML.


I know these concepts can sometimes be confusing, so I'll do you a favour. I know you chose that particular phrase and its adjectives by copying boilerplate from someone else's framework. So I'll rewrite that phrase for you. Your framework is a "brittle and anaemic collection of unrelated and disorganized files that, in fact, is incapable of operating with Smarty."

Don't feel hard on yourself. You are actually part of a proud tradition of programmers. Programmers who looked at the field of languages, higher-level syntax, forty years of best practices and brilliant semantic representations of data and control structures and decided to turn their back on all that and create a mockup of the same. A mockup that has all the elegance of a tumbling box of wire coat-hangers, all the syntactic cleanliness of a closed sack of collier's boots at the bottom of a mudslide, and a sense of data storage and retrieval as transparent as the accounting ledger of an aging mobster on benzedrine with dyslexia.

Yes, you are part of the proud tradition of PHP. Give yourself a pat on the backside. If you can find it. With both hands. Perhaps by version 17, PHP will have reached the straightforward clarity of TCL.

Yours sincerely,

Barry King

Comments

( 2 comments — Leave a comment )
muneraven
Jan. 28th, 2011 08:05 pm (UTC)
We lol'd
I lol'd at the wordplay and my partner Tambyrd lol'd at the frustration with bad programming.
barry_king
Jan. 30th, 2011 04:53 pm (UTC)
Re: We lol'd
Didja get the joke? Tool Command Language? As in "go jump off the bridge, you TOOL!"

Irony is that my preferred language is perl, that's even more dank and murky than PHP. Actually, it's more like a city, with some nice, clean neighbourhoods and some awful filthy slums. In PHP, though, they keep bulldozing the slums and building more slums on top. Java is more like a city like Jericho: many cities built exactly the same on the ruins of the previous city.

C, however, remains like a sewer system. Utilitarian, necessary, and maze of twisty little passages, all alike. When C++ came along, it was exactly the same, only modular like a suburban development.

I need to take up python, which I hear is like one of those dutch triumphs of urban planning.
( 2 comments — Leave a comment )