Saturday, August 28, 2010

The Zombie Plain

I have just come back from the programming zombie plain. In this case, the Android operating system.

If you are a 'real' programmer, you have been to a zombie plain. To others, you seem as shuffling oblivious to the rest of the world, except for one goal that common humans cannot fathom. Like a regular zombie, you are preoccupied with the ultimate goal similar to a succulent brain.

My adventure was a little disorganized. I had never programmed on Android. I had a few books, but to put it simply, these books were written by other zombies, perhaps possessed as well by a publisher with a deadline, not humans. I am a great Java programmer, but Java is only as good as your tools libraries, and documentation. Sadly I was missing all of these and was stuck shuffling in search of a design that works.

The menu items of zombie programmer are the little pieces of software you need to get working. With standard programming, these are hard enough to all make work at once, add a phone OS and we have a whole new level of desire for our gray matter. Phones now have their own user interface libraries, special ways to configure, wacky features like a screen that rights itself to the correct orientation (maybe), and worst of all an application lifecycle that starts and stops the application because of slightly more important tasks like phone calls or an important email. Mobile phone programming is like taking the simplicity of zombie brain chomping and moving upscale to cook your brains in the style of French cuisine without a saute pan or a whisk (a good merlot brings out the overtones of neurotransmitters).

Back to the shuffling of the zombie programmer. As a zombie you go from one scent of brains to the next. Zombie victims of course do not just sit there and wait for you to finnish spooning their cranium, they keep screaming and running away. Same is true with programming and worse on Android. Fix the screen to work great in portrait mode, then it stops working in landscape. Get landscape and portrait to work and suddenly the app won't talk with the camera.

The tools you use are another matter. They are akin to the shuffling. Zombies are not coordinated and neither are most development tools. Just when you think you have solved your problem, nothing seems to change and the application too is undead. This is of course a ruse. The tool is simply playing undead to fool you. Really your fix worked, but you keep shuffling on to other solutions that all fail to work and you probably forget the best fix that would have worked if the tool was listening to you.

The tools for Android are quite tricky. Once they figure out how to fool you, the only choice is to shut it all down and start again. Luckily most of the evil goes away when you hit reset. Sadly there are still things the tool remembers. The debugger might work again, but you can't compile because some setting was permanently munged. Between resets, you are blowing things away and starting over. A fine example of this evil was adding a sound file. Add a folder and the file, it stops seeing this R.java file. If you add the folder, delete the generated R.java, then add the sound file, it all works. Sadly though the sound file won't load...

DISCLAIMER: We here at Boys Books don't want to mislead you. Everything here is true. However, it is our own alternative universe of truth. Try this on another computer or someone other than your identical twin, or evil twin, it really does not matter, all the problems are all different with solutions to our issues are unrelated to yours. The only truth here is that Android programming is like a vacation at a high-priced beach resort, in Hell. This is why programmers are generally highly compensated, it's hazard pay and helps pay for PTSD therapy.

Zombies are never satisfied. Same goes for software developers. Here is the problem. Applications should have lots of features and of course be perfect. What the brain can imagine, the programmer must develop. Imagine writing science fiction. You imagine a big spaceship that travels faster than light. Now imagine building that spaceship... That's the joy and frustration of programming. Cool to imagine, satisfying to know you are creating something cool, but frustrating because of the impossibility of the dream. Oh, then add wacky tools, sad libraries, and programming languages that are not very good at mind reading.

Welcome to the zombie plain!