Last week, we found a problem in our recently released software product. It looked like a problem with a part of the program I was familiar with so I was given the task of checking into it. It turned out to be a problem in another part of program that was affecting my part of the program. While I could fix the problem at that point, it meant that the corrected program wouldn't be released to our customers until the whole new version was ready. There are a number of things being added, improved or fixed before we release the next version.
But there is a nice feature of Object Oriented Programming languages like the one we use, Java. If you create a new section of code (called a Class in this type of programming) derived from an existing section (Class) in the code, you can override parts of the existing section of code. Another aspect to this is that there is a part of our program that is a separate plug-in to our main program and is stored in a separate file on the computer. This way, I would only have to change one small piece of the program and we could send it out to customers before the main program would be ready. They could easily update the program with this new plug-in file and fix the problem.
So, I worked on the plug-in, overriding the piece of the program with the error and made a new version of the plug-in and tested it. It worked! On my machine. But to fully test it, I needed to use a test machine that was in the same state as a customer's computer would be and then load the plug-in there. When I did that, it didn't work! Did I mention that this all happened on a Friday afternoon? I stayed as late as I could but I couldn't figure out what was wrong. So, I had to head home to worry about it all week-end. Normally, I could work on this from home but we already had a busy week-end planned (like going to the reunion as I wrote about previously). What little time I had, I used to scour my books and the Internet for reasons why my overriding code wouldn't do what it was supposed to do. How could I make such a fundamental mistake? Did I really understand these things as I thought?
Finally, Monday arrived. I was both worried about the fact that I didn't seem to know as much as I thought about this type of programming and excited about getting to it and fixing it. After a few more hours of looking for possible reasons why my solution wouldn't work, I decided to try it one more time to look at the symptoms. This time, as I went slowly through it (instead of rushing to just be done with it on a Friday afternoon), I noticed that when I added the new plug-in to the program, there was a check box in front of it when it shows up in the plug-in manager - and it was unchecked! The plug-in had been disabled so no wonder it didn't work. I checked the box to select the plug-in and everything worked as expected. What a relief.
So, another lesson learned in life. You can't just worry about the fancy, fun stuff. You have to think about the boring details, too. But I'm 59 years old. Shouldn't I have learned this lesson a long time ago?
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment