Monday, June 09, 2008

Finding Bugs on Atlas Quest

I woke up, bright and early this morning, knowing I'd have a long day of fixing bugs on Atlas Quest. The first thing I did, before I even turned on the computer, was to pour myself a bowl of granola cereal, sprinkle some blueberries on it, drown them in milk, and eat. My brain, I knew, needed sustenance, and heaven forbid, it might be a long time before I could fix all the problems I knew would be awaiting me.

After breakfast, I turned on the computer to survey the damage. Immediately, a big, red button that said "View Errors" popped up. It's the first thing I see when I log into Atlas Quest and it has recorded errors. It's bright red, it's ugly, and it gets my attention. =) I did note dozens of new messages were posted to the main AQ message board and help boards--never a good sign. Only two new messages to the webmaster board--perhaps bug reports. Perhaps it was just Wassa heckling me. I couldn't be sure until I read that board, however. And I had about a dozen AQ mails in my inbox. But all that could wait. First thing's first--the errors Atlas Quest itself recorded.

I like to work on these errors first for a couple of reasons. One, when Atlas Quest can detect and record an error, it also records exactly what page someone was viewing at the time, who was viewing it, the precise error that was recorded, and when it happened. It's usually very quick and easy for me to diagnose and fix these errors with all that detailed information. And by the time I've gotten through them, usually it's fixed a good number of the error reports you humans have posted or e-mailed me with. =)

Then I started working my way through the main Atlas Quest board, looking into problems, fixing more bugs. There were a lot of questions as well, but I put most of those aside to reply to later--bugs first. Must fix things that are broken, then I'll get around to replying to people.

After getting through that message board, I hit the help board. Then I went through my AQ mail, then back to the message boards to check those two posts on the webmaster board (alas, just bug report and no heckling from wassa this time around), and finally to the postal and LTC boards since I figured with the substantial update to the trackers, there would be an unusually large amount of questions and problems reported there. I usually don't follow those boards.

And of course, once I made it through all those bug reports, I went through it all over again, since by the time I went through all that, Atlas Quest had recorded more bugs, more posts were made to the various boards, and additional AQ mails were sent to me. I had to go through several iterations.

It's now 7:00 in the afternoon--normally, I'd consider 7:00 evening, but it's still too light outside for me to think of it as anything about afternoon. I did take off about a half hour for lunch, and sure enough, by the time I got back on Atlas Quest, more bugs had been found and recorded.

Which is great--you people are awesome at finding bugs for me. =) Most companies will spend millions of dollars to pay people just to look for bugs in software. At Intel, we called them "quality assurance" or just QA for short. Interestingly, most developers didn't much like the QA department because--get this--they'd find bugs in the programs we would develop! Hello? That's their job!

I always got along well with the folks from QA, and I'll tell you why. I don't really like finding bugs. It's a tedious, boring process, and if some other schmuck from QA wanted to do that for me--by all means, I was happy to let them. =) It's like a game--I'd try to create code that they couldn't find problems with.

Of course, I always lost that game. Software is a tricky thing to develop and get right, and the folks in QA would always find problems. Sometimes, I'd find the strange bugs they did find rather impressive.

There's one instance in particular I remember. Our group had developed a Windows application, and you could bring up a "Save as...." dialog box in two different ways. The first was to use the menubar and pick "Save as...." from the drop down list. The second was by pressing Ctrl-A.

QA discovered that if you opened the dialog box in one manner, the title of the dialog box read "Save as...." while if you opened it the other way, the title of the dialog box read "Save as..." -- can you see the difference? One had four periods after the words, while the other only had three. It was strange behavior because they were supposed to be the exact same dialog box. Why were they showing up with different titles?

Now as far as bugs go, it was ridiculously unimportant. It was strange, however, and not expected, so QA went ahead and recorded it as a "cosmetic bug." And when I heard about the bug, I was astounded. How the heck did they FIND that?! Talk about attention to detail. I probably would have never noticed that problem in a hundred years. I was impressed with their powers of observation, and out of sheer curiosity, I wandered over to the guy who submitted the bug and asked him, "How'd you do it? How'd you find such a tiny, microscopic bug?"

His answer: Mostly just dumb luck. =) He was playing around with things, opening and closing windows, over and over again, and just happened to notice the discrepancy in the number of periods used. He wasn't even looking for anything in specific--just eyeballing stuff to make sure it looked right to him.

One of my immediate co-workers, who shall rename anonymous since he wrote this particular section of code, was furious. "Why are they wasting our time with such stupid little bugs?!"

It's true--the bug was not a deal breaker by any stretch of the imagination. It's unlikely any clients would ever notice such a thing. The way I saw it, however, was perhaps--just perhaps--it was a symptom of a much bigger problem we don't know about. The proverbial iceberg, and we're just seeing the part that's above water. I wanted to know why this was happening, although given its purely cosmetic nature, I wasn't going to expend a great deal of energy to solve the problem. I'd just take a quick look at the code for five minutes and if I didn't find the problem, I'd go on to more important issues.

I did find the problem--a strange line of code that read something to this effect:

if the dialog box was opened using the menubar
set the title to "Save As...."
otherwise
set the title to "Save As..."

That's it. So I took out the if/else statement and set the title to a consistent value regardless of how the box was opened. I suspect the code somehow ended up in that bizarre state due to a bunch of copying and pasting--this particular person that developed the code was notorious for lots of copying and pasting--and probably wherever he copied it from there was a reason to set the title differently. I don't really know, and then in his quest just to get the code off his desk, changed the titles without actually reading the code and accidentally used an inconsistent number of periods.

So I fixed the problem, and felt a bit better knowing that it wasn't a symptom of a larger issue under the surface.

What's all this have to do with Atlas Quest? Nothing, really, but it's an interesting story, don't you think? =) Of all the bug reports I've gotten over the years, that's the one that amuses me the most because I can't imagine one person in a million would notice that sort of thing. But all the same, finding bugs is terribly boring.

And on Atlas Quest, this is essentially a one-man operation. I could have spent a month testing all the new code I created for these trackers, but you guys probably found more bugs in the first 12 hours after I uploaded it than I could do on my own in a month. That essentially makes you all my QA department, and you're amazing at what you do. If you're looking for a job, you might consider applying for a the QA department. (But note, most developers will generally hate the job you do. I'm still astounded how most developers seem to seriously dislike anyone associated with QA.)

And even better, I think a lot of you even LIKE trying to find bugs on Atlas Quest. =) It's like a game for you--who can be the first to identify a problem.

Yesterday, I told Amanda that I was planning on the big update late last night, and she was thrilled about being able to list a Nancy Drew LTC or something--I don't even know what she was planning. She was disappointed when she realized I wouldn't be uploading the changes until 11:00 at night since she would have to leave for work before then and wouldn't be around first thing to add her tracker.

"You don't want to list your tracker the first day," I told her, "because it's gonna break. Let others find all the bugs for you, then it'll be working smoothly by the time you get back." =)

She nodded, agreeing that it's probably best not to be first, but she seemed a bit disappointed that she couldn't put herself on the front lines, sort of speak.

But to make a long story short.... thank you all for all the amazing work you've done finding bugs. Some of you seem to apologize whenever you find a problem, perhaps afraid that you're being a bother, but I depend a great deal on your powers of observation and testing to help me find bugs, and I appreciate the help more than you can imagine. =)

So thank you, for every one of those bug reports, no matter how small or insignificant it may seem.

-- Ryan

6 comments:

Anonymous said...

Any chance of a virtual letterbox for helping with the bugs? That is making the finding of a bug at AQ a virtual somehow?

Anonymous said...

well, as usual i love the story.......but i really don't like the image you have with it. i raced through the part up close to it so i could scroll down past it.

you know how you said you like being told about the bugs and some of us seem like we are bothering you.......made me chuckle this morning........

you see yesterday i was trying to check one of my saved searches and all it would show me was the mystery ones in that search no matter how many times i unclicked the mystery box...........finally i told myself ok, ryan has just done major tweaks and changes, it will be fine in awhile....i knew i wouldn't be the only one finding it and didn't want to bombard you with notices and yup this morning it is working just fine.

maybe we could have a bug report page, something that just list what bugs have been reported. not sure how it would work......program wise.....but look like the letterbox directory that shows the different boxes in different area.....

yeah i know more work.........just like the QA, there must be the IDEA department.....we work for both departments.......that is what you get when you invited us many years ago into your world :J

we love you and your world.......don't yeah just love us too :J

condo

Anonymous said...

"And even better, I think a lot of you even LIKE trying to find bugs on Atlas Quest. =) It's like a game for you--who can be the first to identify a problem."

Well, we ARE treasure hunters afterall. It's often important to pay attention in this game :-)

pre

Anonymous said...

I am a QA manager (promoted up through the ranks). Hee Hee....
Sweet n' Sassy

Anonymous said...

Oh gross! So glad you are the exterminator man, not me!

Anonymous said...

Yes, it IS an interesting story, to an ex-programmer. It's always difficult to find your own bugs, and you can't adequately test "pilot error" on your own stuff. I remember thinking "why in the world would you click on [that] and [that] at the same time?"