Consider this picture your moment of zen. We’re about to dive into nightmare territory.
In the first week of class, I was pair programming, and we’d reached the point (one of fairly dozens that day) of editing and troubleshooting. We use Sublime Text 2, something I’m fairly used to at this point; what I wasn’t used to was Ubuntu. I hit an F key without meaning to; suddenly, our window maximized, and neither double-clicking nor dragging the top bar of the window down made it shrink. The maximized Sublime stared at us from two mirrored monitors, waiting.
So I began tapping the F keys again, one by one, thinking it would ultimately undo what I’d done, and I might learn a couple shortcuts too. This is a practice that has served me fairly well for the last 20-odd years, with not a casualty to speak of.
Til that day, anyway.
Somewhere around F-8 or F-9, all of our lines of code rearranged themselves. Instead of our 40-plus lines of tidily indented work, they had formed a perverse pyramid, blank rows at the top, and the rest below in order of descending indentation, alphabetized within those length blocks. Under the edit menu, undo was greyed out.
I think – I think – that I managed not to actually say “What even the fuck?” in front of my pair. (We were all still using people manners then; now there’s a post-it in one of the bathrooms telling you to drink more water, lest you get constipated, a problematic situation the post-it writer knows very well, ok?)
I called over my advisor, explained the situation, and watched as she tried a few of my steps again. No undo. No solution. Nothing.
She frowned and said words that were not meant to be an indictment but were nonetheless: when was the last time you committed?
It was about 5:50 pm. We’d last committed after we’d finished our last exercise. You know, at 1 pm.
“Well,” she said finally, rising from the keyboard. “You learned something.”
“I did,” I told her. “And I’m not – well, I’m not proud. But it’s not often that a person really manages to break something beyond repair with computers. It’s… notable.”
She shrugged and went to help less hapless people. I apologized profusely to my pair, who was altogether lovely about it.
I thought for a moment and closed Sublime. I counted to three and reopened it.
Our properly ordered, fully functional Python file was restored.
I’m not sure I took a whole breath in before I completed a commit on it. And now I, like all of us in our time, am a committing zealot. Early, often, excessively.
I don’t recommend being an anxious person. But for certain qualities? I totally recommend hiring them.