Tiny Bug, Big Tiny Effect

I just fixed a teeny tiny bug in my relicensing script.

While recursing, it was checking directories against the excluded list by doing an endsWith(). However, one of the directories to be excluded was “ef” (Electrical Fire), an obsolete piece of debugging code, and it turns out that this was matching all directories ending in “ef” – like, for example “pref”.

This small fix has revealed 3500 more files to be relicensed that heretofore I had not suspected the existence of. In fact, I only noticed because I found a freaky file with an NPL header but MPL text, and did an LXR search for “NPL 1.1” to see how many like that there were. Anyway, hopefully my script will make fairly short work of them.

Today’s lesson then, children, is: Don’t trust new tools absolutely. Run cheap cross-checks.

[Update 5.47pm]: OK, so the fix had a bug. The actual number of files is 91, not 3500. Second lesson for today: don’t be too eager to write blog posts explaining your own foolishness, lest you demonstrate it to the world in unintended ways…

4 thoughts on “Tiny Bug, Big Tiny Effect

  1. James: Not very much; but after four years, I’ve grown wary of giving dates :-) It’ll be done when it’s done; but the Foundation does see it as a priority, and the time I’m spending on it reflects that.