Why programmers should study Microsoft’s random failure and not trust Google search

The bizarre story of the EU-mandated Windows browser choice screen took an unexpected twist recently when it was noticed that the order of the browsers was not truly random.

image

IBM’s Rob Weir was not the first to spot the problem, but did a great job in writing it up, both when initially observed and after it was fixed by Microsoft.

It was an algorithm error, a piece of code that did not return the results the programmer intended.

Unless Microsoft chooses to tell us, there is no way to tell how the error happened. However, as Weir and others observe, it may be significant that a Google search for something like Javascript random sort immediately gets you sample code that has the same error. Further, the error is not immediately obvious, making it particularly dangerous.

I am sure I am not the only person to turn to Google when confronted with some programming task that requires some research. In general, it is a great resource; and Google’s own algorithms help a little with filtering the results so that sites with better reputation or more inbound links come higher in the results.

Still, what this case illustrates – though accepting again that we do not know how the error occurred in this instance – is that pasting code from a Google search into your project without fully understanding and testing it does not always work. Subtle bugs like this one, which may go unnoticed for a long time, can have severe consequences. Randomisation is used in security code, for example.

As an aside, there also seems to be some randomness in the appearance of the browser choice screen. It turned up on my laptop, but not on my desktop, although both have IE as the default.

And who would have guessed that the EU would arrange for so many of us to get an ad for something like the GreenBrowser popping up on our desktop? Apparently it is the “best choice of flexible and powerful green web browser”, though since it is based on IE it is less radical a choice than it first seems.

image

One thought on “Why programmers should study Microsoft’s random failure and not trust Google search”

  1. To be fair, this is not the fault of the Google search product, but more the overall search phenomenon and how we relate to information today.

    Look at the programmer 30 years ago. We would have a bookshelf with a few trusted books: a language reference, an algorithms book, maybe a book on programming style, user interface design, a few specialized books on various tools and libraries, and then a stack of magazines and journals. That was it. To go beyond and answer questions not answered in those references required that we get up, walk down the hall, talk to another person, pick their brain, see what they had on their bookshelf, see what they knew. We still “searched” for information, but it was more social and we could easily judge the source of information based on reputation. There was an emphasis on “wisdom” over mere “information”.

    But today, we have immediate access at our fingers to a nearly-infinite stream of information, but it is far harder to judge the accuracy of the information. This is not just with programming, but with many areas: medical advice, financial advice, etc. We substitute a much larger quantity of information and pretend that search can turn it into wisdom. The downside, of course, is that we might be less likely to talk with our doctors, our financial advisers, or that experienced master programmer down the hall. I think we lose something important when we do that. We may have more information, but that does not equate to having more wisdom.

    Does the web make us smarter? Or just more efficiently mediocre?

Comments are closed.