Writing A Spec Way Too Late

So what was a wonderful project to start with became a nightmare, but I finally see the light at the end of the tunnel with it. Because this project started off so innocently, and became such a disaster, I feel like I should share some of the mistakes I made along the way, and some of the insights that I have gained in both 1) extracting myself from the problem and 2) not allowing myself to get sucked into issues like this again. So lets start with a little bit of history of the project and the situation and go from there.

The development company, which I will refer to as “E” in this post is one that I have worked with for a while. They are good, skillful and friendly, they also do have a history of not generating sufficient (or any) spec’s for projects before they sign deals. This is a known problem, and something that both developers and designers have been complaining about for a while.

Continue reading Writing A Spec Way Too Late

Time Tracking Software

The development team where I work is going to start tracking the time spent working on each project. Although in some ways this feels like a bureaucratic hassle, it will be useful as far as justifying our existence and provide some ammo for why we shouldn’t tackle every suggestion that crosses our desks (e.g. the “trivial tweak” that actually take 12 hours to implement).
Clock
Continue reading Time Tracking Software

Adobe AIR and digital certificate password length

I’ve received several e-mail messages over the past couple months letting me know that the desktop magic eight ball application I created for a beta version of Adobe AIR no longer worked.

Naturally, it wasn’t the highest priority on my to-do list, but I finally decided to get around to it. But I kept getting an error message: “no such file C:\air\eightball\in”
Continue reading Adobe AIR and digital certificate password length

Emacs and osX

I am a huge emacs fan, to the point of having written my own major mode for working in coldfusion when I couldn’t find one that satisfied (rather than moving to another editor) Its something that I see as part of my personality, almost like a political affiliation. I also happen to be using a mac at the moment, and my first few tries at using emacs under osX went pretty poorly, but I did work everything out, and I thought that I would write about it some to save everyone else the trouble.

First off, I initially tried just installing a standard version of emacs and using it through the terminal. As it turns out that has a lot of problems, particularly with keys being in odd spots (the meta key behaves a little oddly) and with the interaction of cutting / pasting / killing and Yanking. The next try was xEmacs under the mac X11 server. That was an instant disaster.

My third try was with aquamacs which worked decently, but I still found to have several frustrating bits of unpolished interaction. I could have lived with this indefinitely, but another emacs fan I know suggested I look at carbon emacs and wow am I glad I did. This is what emacs for mac should be.

The only major change I needed to deal with is adding (setq mac-option-modifier ‘meta) which made the damn meta key work in a way that doesn’t drive me nuts.

So for those of you on a mac, consider having a look.

Very Frustrated with mysql on the mac

So I just discovered a little bug with mysql in general, and which I am finding extra frustrating on the install I have set up on my mac. The short version of the problem is that if you have a whole lot of tables in a database the application “mysqldump” no longer works, producing

Got error: 1016: Can’t open file: ‘./<database>/<table>.frm’ (errno: 24) when using LOCK TABLES

So I followed up on this, and it seems like this is a somewhat known bug. In particular the problem is noted here: http://forums.mysql.com/read.php?28,162893,162893 along with a solution. However for some reason the mac version of mysql is not obeying the open-files-limit param, either when I pass it through the command line of mysqldump (which doesn’t recognize it as a viable option, or when it is set in the config file my.cfg and rebooted. I happen to be runing mysql version 5.0.51a

SEO and title tag density

How does keyword density in the title tag affect search engine placement? On Facts about Title Keyword Density, it says that Live.com rewards high keyword density in a title tag, whereas Google.com punishes high keyword density in a title tag.

I don’t really care about search engines other than Google. I’ve heard SEO experts claim that Yahoo! and MSN/Live still contribute a fair number of clicks, but that’s not true according to my server stats. I’d like to find out if Google really does punish keyword density in a title tag.

I created 3 similar pages for a fictional person, whose name currently return zero results in Google. Using the name as the search term, there are 3 different keyword weights.

  1. Test A (100%)
  2. Test B (50%)
  3. Test C (9%)

This may not be the best test methodology, but at least it’s a start. In a few days, I’ll see how Google ranks them. Any opinions on how the pages will rank?

Cake CleanUpFields

Yesterday night I managed to get stuck on my cake project it two separate places, which is sort of amazing since I have only been stuck with cake once other than that on this project. (To Be fair, One of the problems is with Plesk, may it’s name be damn for a thousand years, not cake)

Anyway, I just solved the other problem thanks to the comments on this post, and I thought I would share.

When you cuse cake’s helper to pick a date/time it builds a whole lot of sub-fields. Then when cleanUpFields is called it stitches them all back together into one date time. However, it’s a little too smart for its own good, it only stitches them back together if it knows about the date-time, and it only knows about the date-time if that field is in the primary model for the controller your working with. This means that if you are using a second model , it wont fix the date-times.

The good news is that their is a work-around for that, you can simply call cleanUpFields again, with the second, or third model name as a param. (I.E. $this->cleanUpFields(‘payments’); )

What I haven’t found a work around for however, is if you want to get a date that doesn’t belong to a model at all. hopefully I will stumble on an answer as I continue with this, If I do I’ll post it in the comments.

Tottling around CakePHP

My research into CakePHP has, up to this point has been pretty positive. It seems to address most of the big issues I have had with other frameworks, and the code and tutorials all look good.

Because it was looking so good, I decided that I would go ahead and give it a whirl on an actual live project. I chose one that was small and urgent. (The urgent part may not have been wise, since for me personally cake is still unproven, but it seemed like a good fit) and I have been pounding out code for it since then.

So far I’m pretty happy with it, the code virtually never makes me cry, though I run into a lot of road-bumps almost all of them seem to be learning curve issues, and I haven’t actually gotten stuck on anything yet, just briefly derailed occasionally.

The Bake application that comes with cake, which is a small php script that lets you generate starting PHP code is really great for me, because it does cover a lot of gruntwork in a snap, though sometimes it crashes when I’m trying to generate specific models, but it’s probably good, for learning purposes, that I’m forced to write the occasional one by hand.

At the moment I still strongly prefer the smarty template engine to the way views are handled in cake, but the two are not incompatible, and it also may be just a case of me being set in my ways. Perhaps when I really get to know the helper functions a bit better I will be happier with this aspect of cake.

Oh, and the one thing that has caused me the most trouble so far is singular vs plural names. For some reason bake messes up the pluralizations when it is generating the rules for many to many models, and I don’t seem to have a feel for what should be singular and what should be plural.

Still, even with all the bitching I’m doing, I’m really happy with cake. I would say that development using it is going about on schedule, which is pretty good for the first time with a framework, and I feel like it is going to save me a lot of pain at the end with debugging and maintainability.

The Greater-Than Gator

I lost a lot of time yesterday thanks to tracking down an alligator in an import utility. There was one itsy-bitsy little function that wreaked big havoc, thanks to a confused gator that didn’t know which way to look.
Greater Than Alligator
That’s right, there was a < when there should have been a >. (Or since it was ColdFusion code, there was a LT where there should have been a GT.)

The import utility was developed by a guy with a masters degree in computer science, so it just goes to show you that no amount of expertise can prevent such an error (or, quite possibly in this case, a typo).

It was an easy fix, of course, but fixing all the data that had been incorrectly imported in the past took a bit longer. It cost me a few hours, but that’s better than causing a credit crisis. Either way, it reinforced in my mind the idea that we could use some unit testing around here. Sure, it might take a little extra time to write the tests, but probably less than the amount of time I spent hunting down the pesky little gator and fixing the mess it left in its wake.