I used to be a programmer. Way back in the day, I wrote great big heaps of BASIC and Turbo PASCAL 4.5 and worked in a few other languages of that era (I may be one of the few people left who remembers Clipper). At one point, a high school friend and I worked on creating our own command-line environment for the C64, for no other reason than it seemed like a fun challenge. I’ve written quite a bit of JavaScript—not like a wizard, but well enough to get some things done—and a fair amount of PHP. These are languages that I understand, that make sense to me. I can make them do what I want to do.
But I just don’t get all these new-fangled programming frameworks. Is something wrong with me? Seriously. I have this grumpy, churlish feeling that I suspect is rather similar to the way SGML experts felt when they saw HTML becoming so popular, and that scares me.
People who’ve drunk the various kinds of framework kool-aid don’t make it any easier, though. “Oh”, they gush, “you should absolutely try Ruby on Rails! It’s so easy! It’s almost like writing regular English!” Which means they’re clearly on crack, because Ruby on Rails is so very different from a human-written language that the few ways in which it sort of resembles prose, assuming you look at it under a dim light through a heavily fractured fresnel lens, serve only to confuse me further. I have many of the same problems with MySQL, actually: by dint of its being sort of human-like in its syntax, I’m led into all kinds of incorrect assumptions about what I can do. Thus I spend a lot more time screaming at opaque error messages than seems necessary, just because I thought a comma made sense when the language didn’t.
I’ve looked at all kinds of different intros and tutorials and “for regular folks” resources, most of which I get from Simon‘s linkblog, for a number of different frameworks. They serve only to confuse me. The CakePHP 15-minute blog tutorial? Didn’t get it, and remember, I can write PHP relatively well (I wrote all of An Event Apart‘s registration stuff using PHP and MySQL, for example). The oft-recommended Tutorial in Ruby on Rails? Lost me, Coach. Even Jeff Croft’s Django for Non-Programmers left me in the dust.
All these frameworks’ proponents say “Just write in this totally simple and obvious way and the messy details will be magically handled for you!” but that’s just not how it works. You have to write in a very specific and unintuitive way, and unless you know specific magic words and what roles they can take then nothing will happen except the return of an error message. This is no different than any computer language, of course. What I think bothers me is that the cheerleaders always seem to believe, or at least pretend, otherwise.
Maybe it’s just that the tutorials never seem to clearly state what’s a piece of built-in magic that I’ll learn about later, what’s something that I’m building myself, or whatever. I mean, look partway through Jeff’s Django piece. I don’t mean to pick on Jeff, because he’s not doing anything worse or even different from the other stuff I’ve read; it’s just the one I happened to read most recently. Anyway, he says, and I quote:
These four lines create a very pretty admin area…. with appropriate entry fields for all of your fields. The “pub_date” field will automatically get a pop-up calendar for choosing a date. The “enable_comments” field automatically knows to use radio buttons for its interface. The “lead_image” field will be a browser-based upload tool. Et-cetera. Without doing a thing, you’ll get an admin interface the likes of this…
That whole interface just magically happens? How and why? Is it part of the Django core? Why? Is it useful for other stuff besides what we’re doing here? How? Did all this happen based on the class I created, or the variables I defined, or the values I gave them? How can I tell? Where can I find a list of the magic things? How can I re-use them; or, put another way, how far will the magic things stretch?
I feel like there’s some very basic, fundamental, obvious thing that I’m missing, but I don’t even have the necessary level of knowledge to frame the right question. Or questions. See? I don’t even know how little I know. Is it that I spent too much time doing old-style programming, and so I’m too suspicious of anything I didn’t write myself? (In which case you’d think I’d be an assembly-language kind of guy, but I’m not. At all.) Is it that for years I taught myself programming languages using reference manuals, so I need that kind of function listing before my mind will start to absorb a new language? Is it just that I’m too old now and my mind isn’t sufficiently elastic to take in radically new concepts?
Basically, my nose is telling me that I’m up a putrescent watercourse and I lack a means of locomotion. Maybe I’m not alone there, but sometimes it sure seems like it.