Today, coding made me think that development is a punctuated equilibrium, too.
I was working in a fairly large codebase with some deep dark corners. Nothing far off what we all do; nothing special at all. I was having trouble getting all the details into my meatspace, but was managing to get things done, code was progressing.
And then I hit a wall of "what the what?"
Happens to me from time to time, when a little detail will stymie me for five minutes, ten minutes, a half hour. Where you twist your head sideways to look at the code and wonder what the heck the code is doing.
I ran into a few of these today. I figured them all out, but they each shut me down for longer than I would want to admit to anyone:
- Where the heck is that css parameter getting set? I can see it in the browser's "inspect element", but I can't see where it's coming from in the code. Not in the HTML, certainly, and not in the CSS. Oh, there it is, right there in the TypeScript file!
- Why the heck is this object serializing to JSON differently than to string? Does the ServiceStack.Text call the ToString() method under the scenes when serializing objects? Is the "override ToString" code section here followed by ToJson() example a typo, or is that how it is supposed to work (My legacy object has a ToString() and a ToJson() method on it, and the service stack uses the latter. Makes sense.
- Where is the bug in my KnockoutJs code? I'm sure I've forgotten a set of parenthesis somewhere, but I can't for the life of me find it. Oh there's the little bugger. Oh yeah, when I want to do a visible check against an observable property, I can check it directly, but when negating, I have to invoke it as a function. A known property of the library, but darnit if I don't forget that sometimes.
Coding along happily, then boom, stuck in the mud. Trudge, trudge, trudge, finally get out and get back in the rhythm, then bam, back in the mud.
Is my solution evolving? Is that why developing happens in fits and starts?
No comments:
Post a Comment