How To Suck At Programming- Put a mandatory reboot at the end of your install script


You have created the slickest software this side of the east coast! People will literally chew through the concrete enclosing the office that houses your cubicle just to get their hands on your latest release. You’ve managed to find a niche that nobody else had even considered. You will become an instant success. Now all that stands between you and the yacht you’re sure to be cruising is the loading of your software on an end user’s machine. You’ve got low level hooks into every facet of the host operating system. That’s what makes your software a killer. Explorer shell integration, low level kernel ties that catch signals on disk writes, the works. A reboot is necessary to activate all of the bells and whistles so at the conclusion of your install sequence you trigger not an optional, not even an ignorable, but a mandatory reboot enforced by a modal dialog box. No time to consult the user, you’ve gotta get your binaries out there so you can sip Pina Colada on your way to Cancoon. The user will understand right? After all everybody reboots all the time! Plus with ubiquity of the Windows operating system it’s almost an oddity to not hear individual computers constantly restarting and playing the Windows startup theme in a busy office.

Never mind the critical and possible unrecoverable work that may be in progress as your installer runs on the desktop of an unbeknownst user. Forget about adding a cancel button so that the save button on an Excel spreadsheet trapped behind your installer’s modality may be clicked. Give no warning about the soon to come power cycling because it’s O.K. In fact it’s so ok that ok is what you put on the only responsive screen widget at the tail end of your installer. The install has completed… square an ok button center of the screen. How about that conclusion message? Pick the best wording to enlighten your users, “You computer has been updated with my killer application which is way more important than the thousands of lives you were campaigning to save with your silly little editorial in the background. Don’t bother trying to drag this dialog out of the way as I have taken liberty to dominate your entire workstation with my insistent dialog. Click the only responsive rectangular button in the middle of the screen to trigger an immediate shutdown and restart rendering the thirty other open windows meaningless and obsolete. Thank you for installing my product and please take the time to fill out my survey which will automatically launch in your browser once your machine regains consciousness.”

So if you wanna appear as arrogant S.O.B. developer, totally screw up somebody’s day, change the tide of the upcoming election, and ultimately suck as a software engineer put a reboot at the end of your install script. The remainder of your installer’s good work will only last a minute but the loss of productivity and pain of unrecoverable work will last a lifetime.

How To Suck At Programming- Use your IM as a password prompt


Don’t act like it’s just me! You’ve been there! You’re hacking away feeling uber productive (I hate the word “uber” because it sounds so geeky) in a Tuesday morning. You got about 15 windows open that you meticulously manage bouncing back and forth between your email and your calendar verifying meetings at 10:30 and 2pm, your IDE and your web browser triple checking the last second Javascript patches that you made to the company site, your command line and your multiple IM sessions as you secure shell your way through the company’s most secure networks while chatting with your neighbor, your buddy from Illinois, and some sys-admins in a totally different time zone. Of course the probability for error is high but you are a trained professional. You pay careful attention to every keystroke you make. You have hot keys to every critical system function memorized and you know how to whiz from the current totally confusing multi-window multi-desktop information overload to a single window focused environment and the click of a button. (The click of the Shift+Ctrl+Home, Escape sequence you custom programmed using a mixture of Groovy, and python over the weekend during the Giant’s Triumph over the New England.) You are completely in control of your multiplexed-multitasked-multi-desktopped universe!

The day continues with a Mac, and two desktops all running side by side using a software KVM your single keyboard and a mouse empowering you with the might of a dictator running a small nation. Check in that source code patch there, respond the Elgin who’s inquiring about when your team’s next release will go live, swing the mouse to the far left (into the connected Mac) to make sure you’re not late for your daily stand up, swing your mouse back to the right (across the WinXP desktop) into Linux land where focus follows your mouse cursor and begin the login process to the production system. What’s that blinking slightly behind your terminal window? Oh that’s your chat window where all of your buddies are hanging out discussing which bar they’re going to hit this weekend! ignore that for now as you sip from your coffee mug and delicately place it back on the desk only slightly nudging your high precision optical mouse. Lets type the old password for the production server, which also happens to be the same password for your email, your online bank account, your employee payroll access center, and about half a dozen other highly sensitive places that you don’t care to be banned from simply because your memory has the capacity of an old 386 machine from the late eighties after an install of Doom. We type fast because we’re professional and we know what we’re doing. We quickly mash the enter key as a reflex to the muscles trained habit of typing the same password 647 times per day. We only realize after the chat window comes to life that the slight nudge from our coffee mug was just enough to move the cursor off of the terminal window and onto the chat window where “focus follows mouse pointer” (because you’re such a clever KDE desktop nut). We have now given the secret keys to our bank account, email, company secured servers, and plenty of other secured locations to the rowdy bunch of compadres on the other end of your connected ICQ Instant Messenger Network.

Well done genius! You not only have the joy of tracking down and remembering all of the servers and websites that your now exposed user credentials belong to. You also have the honor of resetting various browser and other software for the next 27 days and tracing bugs due to authentication failures where these same credentials were hard coded in local text files among other places. So if you wanna suck at software, use the single user id password system. Exposing it to the world over an IM or an email goof only hurts twice as much as leaving your gas oven on during a vacation to Tahiti.

HTSAP #2 – Prank the wrong PC


HTSAP my acronym for the soon to be ignored serious How To Suck At Programming. Welcome to listing number 2. (Listing 1 was a couple of weeks ago.) Don’t get comfortable because I’m inconsistent with my blog posts.

You’ve been planning this prank for weeks. Your buddy, the guy that works on the database team, is notorious for doing crazy stuff. Just last week he covered the optical eye on your mouse with clear tape and scribbled it with a black sharpee. Just enough to let a minimum of laser through thereby giving you the painfully frustrating user experience of a slow, barely responsive on screen pointer. No matter how far you drag up down left or right the thing only moves a few pixels. As you struggled for hours losing productivity that day, surfing the web, installing new drivers, and plugging into different USB ports, and rebooting not truely knowing the source of the problem it was this guy, barely containing random snickers, that was completely responsible! You’re going to get him back! You’ve watched his every move, waiting for him to leave his workstation unlocked so you can meticulously deploy you rouge program. You know the one pr0n site that the company’s filter’s don’t block, it’s complete with audio and full motion video. You’ve delicately crafted a Visual Basic program that will popup dozens of windows to this site playing the audio at full blast while re-spawning on a reboot. Your team has been held up in the basement of the IT wing of the company where nobody but the cleaning lady visits and you’ve cleverly calculated everyone’s work schedule so that your time-bomb will detonate early in the morning just before the dev team’s daily stand up meeting but before any of the executives arrive as to mitigate the overall collateral damage and avoid getting him or anyone else fired. This will be too good you exclaim mentally as you complete the installation of the devilish COM object along with the hidden Windows registry entry. It’s too perfect as he never leaves his workstation unlocked you think to yourself.

Unbeknownst to you he intentionally left his workstation unsecure after backing up and clearing his hard drive for the 6pm hardware guy to swap the box with an upgrade. You were too into your plot to even notice the default Windows wallpaper or that he was logged in as Administrator instead of his user account. The swap is made promptly at 6pm after everyone including you, has left for the day. His desktop is replaced with an identically looking Dell with extra RAM, HD, and a souped processor. Meanwhile his old Dell goes to the nice always church going Christian lady down in pricing who had recently suffered from losing her husband to internet foul play on the Chris Hansen show visiting chat rooms in that very same site that leaks through the corporate proxy servers. Well done genius! Your carefully attack is about to become a painful re-enactment of a tragic event for an innocent bystander! Of course you have no knowledge of how badly your prank is about to backfire, especially since you’ve left your signature all over the later to be discovered malicious app. You come in the next day fully expecting to be entertained while your buddy opens up Internet explorer as he is predicted to do just before the stand up. To your amazement nothing happens! He logs into the project management tool from his browser and on goes the rest of your day… completely eventless and void of laughter. As you ponder how your payload could have failed to execute (you registered the COM object and carefully placed the registry entry) you begin to hear screams from the pricing office upstairs. These screams are coupled with all too familiar audio of not so innocent grunts and moans played over a pair of Logitec speakers. So if you wanna suck at programming prank the wrong PC. You may never be able to explain your true intentions to the woman who lost her husband and now her final strands of mental stability but the memories of how good that prank could have been should be more than enough to compensate.

How to suck at programming – Announce a feature hot-deployed to a live server without testing


(Loosely based on a true story… as a tribute to a new WordPress blog that I find very amusing… The idea here is NOT original and I can never be that witty!)

You’re the master of your domain. The one person responsible for making sure the build/deploy system is operational. Also, you’re the only developer who actually knows what’s going on in that tangled mass of technology that nobody else in the company uses but you. Sure it’s different and complicated… but that’s only because the rest of your company co-workers are weenies and don’t have what it takes to sit through 532 pages of text describing the ins and outs of Agile Software through the build system. All they know is their fancy wizards for compile and deploy, but you… yes you, the REAL software engineer know everything that goes on underneath. You can describe each tool involved in the build lifecycle down to the byte code level. That NullPointerException, that wasn’t a programming flaw! That was the team’s resistance towards your efforts externalizing the dependencies! They always assumed that they could reference a member variable directly without calling through the getter method.

At any rate, you’ve become professional. You’ve done hot deploys in your sleep while dreaming of sugar plums and dancing daisies. You once did a hot deploy remotely over dialup with a keyboard that was missing the enter key and space bar! Your expertise is matched only by the sheer number of both cold and hot deploy’s you’ve performed over the years! Why should this one be any different? Besides, the code has been tested on your development server hasn’t it? Forget about that staging area specifically set up for Quality Assurance which mirrors the hardware and configuration of the production machines! Completely bypass policies and procedures checks, and balances set up to protect the company from failure. You know better your your methods are fool proof. Just one command and you’re off and running! deployment never felt so sweet.

You draft an email to the project manager as well as the product owner as you watch the text whiz by in your command window while the hot deploy carries on. “New feature rolled out!”, goes the subject line as you inform all of a successful update completely leaving out the fact that it is still in progress as you type. The deployment completes only seconds after you hit send in Outlook. Time for an early lunch your stomach craves reminding you that you have absolutely no work left on your plate between 11:30 and 12pm while the rest of the company marvels at the new features you’ve unleashed into production.

You high five your buddy that sits across from you bragging about how awesome you both are for totally beating the deadline. You crack a joke about some of the corners that were cut and how nobody will ever notice the easter egg you snuck in as an added bonus. Alls yuh hafta do is enter the Contra code during the splash screen in your Swing based app and a mini Super Mario jumps out. This was included as an insider’s joke on the other hermit developer who actually called out “Mario” in the Olive Garden restaurant the company dined at last year thinking he saw his long lost cousin from Italy. You are totally unaware that your hot deploy only went to one of the 25 production machines situated behind the load balancer that your deployment tool talked to and that you have no security to manually update the others. You are also unaware of the impact this will have to the Fortune500 client that accesses your software remotely… totally unaware of the financial loss that is soon to come from the next seven hours of down time spent diagnosing and finally fixing the problem.

The phone call comes in just as you grab your shades ready to head out in the summer light on your way to an 11:30 dine in at the local buffet. It’s your manager on a call with the director that just got chewed by the CEO. Clueless and unaware that the director is on the line, you answer with arrogance because you two have this understanding from way back when you managed to fix a problem by remotely rebooting twelve Linux machines while on vacation in Jamaica. However the era of you saving the day have long passed (it’s all about what have you done for me lately) and he sounds unamused by the joke you mumble over the phone to him while his boss listens in… a rather serious man who has already begun paper work to hire an assistant manager who will likely assume a direct management over your department. Your manager was unaware of your plans to run the update and only found out about the fiasco after receiving a barrage of phone calls and emails which over took his inbox like angry Persians fighting the Spartans in the final scenes of 300. It’s too late to claim ignorance of the event as you’ve already sent the email company wide. It’s times like this you wish you knew more about automated integration testing. So if you wanna suck at programming, hot deploy to a production box at the same time as you claim success. You’ll only spend the next nine weeks looking for employment before taking a gig at reduced pay but the lesson will last a lifetime!