Monday, June 17, 2013

The difference between confidence and hubris.

I've had this nagging fear for some time that I'm really not up to coding for a living because of something a teacher said back to me in college.  It's amazing how easy it is to plant the seeds of doubt in a person's brain.  "You're not what I think of as a prototypical code monkey" he said to me ...and then it stuck.

Granted, there were plenty of reasons to be suspicious back then.  Back in college I spent a whole lot of time learning how to be a human being.  I haven't always been very socially adept.  College was my chance to change that.  I'd also been plenty sheltered and college was my chance to change that too.  So while I did a whole lot of exploring, after the first year in college I didn't do nearly enough sleeping or schoolwork and my grades took a dive pretty fast.  It also never occurred to me that I'd need to do an internship over the summer, so that I'd have relevant experience in coding, or at the very least a language I knew well sitting on the top of my head for the next few years.  I suspect that would have expedited my learning curve for programming languages as well as my job search after college.  But such is life.

My first job out of college wasn't even a job, it was an an internship, and while the company looked excellent on paper it left much to be desired once I started working there.  The whole thing was pretty much the work of just one guy, and so it was prone to his mood swings (which were often) and his particular willingness to move things forward (which was random, but not often).  While it gave me some practical experience programming, being exposed to the boss's mood swings left me somewhat traumatized about the whole idea of working/coding in general which was something I carried forward with me.

Jobs later I think I've mostly dropped that particular fear, which is good because it was never particularly rational to begin with.  However, that first doubt has been harder to dispel.  In spite of all the working code I've written, and all the functioning projects that I've completed some part of me still wondered if I was really cut out for all of this.  That's when a job got dropped on me that was a challenge, something that would test my skills so I could see what I was really made of and that's what lead me to the question of hubris or confidence.

I certainly believed when I took the job that I was up to the challenge.  After all, I don't like to set myself up for failure, in addition to being bad for the ego, it's also bad for professional development.  Part of having companies continue to hire you is having something you can point at and say "I did this".   At this point I'm not sure if I can definitively say that I have hubris or confidence, but I do feel good about my efforts in any case and I feel like I've freed myself from the specter of my initial doubt.

That job was in many ways a disaster.  They hired me without testing for any of my technical abilities because their site was on fire.  I started working before I even signed paperwork to say that I was part of the company.  After a week or two in I was working 100 hour work weeks in an attempt to get everything done.  After getting started on the project I had to restart twice, once because someone else offered to help and then a second time because the framework we'd chosen was poorly documented.  My understanding of the person's time that I was working with was way incorrect and as such poor estimates were made for ETA's.  Also, having never worked with that particular individual before I found that we kept blowing up each other's work, although I think his mistakes wound up costing me more time then the tweaks I asked him to make.  At each step in the project as we began to work on something we'd discover that it was infinitely harder or more complex then we had anticipated.  The cart for the website, which was supposed to take 2-3 days wound up taking a week, and some of the more esoteric parts of the website (image upload to CDN and Netsuite syncing) wound up having additional requirements and complications that weren't initially part of their specifications.

While most of these problems are the usual thing that you'd expect as a bi-product of programming there weren't any coping mechanisms in place to help us deal with them.  Not tests of any kind on the old website to determine if things were working or not, no documentation on what pieces went where or how it all hooked together, and at the time we started no way to keep track of the work we were doing, or what we had left to do.  At some point a haphazard attempt to track things was left in github, but those milestones were far too generic to really mean anything.  So when we failed to hit something it wasn't always clear if we'd actually failed, or if it was part of some other piece.

[frontend]
In spite of all of those things, what did go well is, I fucking built that shit.  Even sleep deprived and with the company burning around me as the site went down over and over again I managed to build some very complicated and very awesome functional programs.  Between myself and the other dev we got the entirety of the website v2's frontend up and running.  Login, cart, categories, checkout, email notifications, order tracking, account details, etc.  All done, all polished, covered in CSS and with the usual javascript to make sure everything was in order.

[backend]
On my own, I got the majority of the back end up and running.  There were still some bits and pieces that needed polish when I left, but overall I was still calling that a win.  Total access to all the relevant bits of data in the database, paginated, searchable, sortable and editable, if they had the right permissions.  In particular I was proud of the image upload to rackspace CDN which both cleared out the original images and then uploaded and refreshed new images, even resorting names if something was changed.  You could see the images displayed on the admin page and even do multiple uploads or edits.

[services]
As if all that weren't enough in my short tenure I also knocked out a services layer.  The netsuite sync was initially pretty bad as I'd never built an asynchronous socket daemon in PHP, but given that the alternative was translating everything I did into SOAP xml calls it seemed like the easier hurdle to cross.  The Netsuite sync was bi-directional as well, so not only did I have to set up a daemon (api) endpoint for the frontend and backend of the website to hit but I also had to set up the routing to get information going the other way, which meant writing the Netsuite scripts and having a web server that the Nestuite scripts could hit in order to pass the information to the socket server.  If you think following that logic here is a headache, then you can begin to imagine what it took to set up.  Netsuite not withstanding I also set up an email processing daemon that handled requests to send out emails to users everytime they were triggered either by new user registrations or the like, because apparently waiting 2 seconds for the API call was too long.

In the end my spree of coding was interrupted by breaking my leg which ate a weekend and was going to take me out of the picture for more days for surgeries, errands for the doctor, etc.  While I can understand the companies decision to terminate me at that point because their world was burning and I'd just announced that for reasons beyond my control I was going to take longer, it was also kind of a dick thing to do.

If I hadn't been tired of working 100 hour weeks I probably would have complained more but in the end I felt like I'd proved myself regardless of whatever else anyone had to say about it.  I'd shown that my faith in my ability to code is well placed, that I can build an entire system from the ground up - servers, frontend, backend, database, service layer, etc - that I can build it on my own, and that I can make the pieces work together and scale.  I think that of a programmer that is more then enough to ask of myself since I'd already proven to myself at the last job that I can do the QA side of things as well, and not just produce code but good code.

So, is my trust in myself confidence or hubris?  Confidence, because I delivered on what I believed I was capable of doing.  It would only be hubris if I thought I could do something and then wasn't able to pull it off. But that's not what happened, I just broke my leg before I was allowed to finish :-P.

No comments:

Post a Comment