I've seen many error messages in my time but for obtuseness, this one takes the cake. It is truly one for the ages. I can just imagine how much time I might have wasted if a Good Samaritan hadn't posted the solution on his blog.
The Error
Here is the logical sequence of my original code (located inside a public static function):
- Set the "default" namespace
- Traverse some XML using E4X to pull out a particular attribute of one of the nodes
- Make a call to another public static function in the same class
The result:
Now I can't claim any great knowledge that would illuminate why this occurs (my guess is that the namespace affects resolving the class + method I'm calling in step 3). Whatever the cause, thank goodness for Adnan Doric who posted the solution.
The Solution
The new (working) sequence:
- Set the "default" namespace
- Traverse some XML using E4X to pull out a particular attribute of one of the nodes
- Reset the default namespace to an empty string ("")
- Make a call to another public static function in the same class
Victory!
The exact line of code for Step 3 looks like this:
The art of computer error messages is one that I, for one, appreciate. My personal favourites are (in no particular order):
Multiple platforms: "Syntax Error"
When I was a kid, I learned BASIC programming (see: Apple II, Commodore 64, Vic 20). "Syntax Error" was the output I most often saw from my little programs. These days, we have IDEs that compile our code and test its syntax on the fly. Frankly, I think that it makes us a little slovely around the edges, in the same way that spellcheckers and texting have lead to near illiteracy among many teenagers... but that's just me.
Atari ST: The Bombs

The first PC our family owned was an Atari ST 500 that my dad bought used through a newspaper ad. I was 13 at the time. We loved that old computer, my bro and I, and put it through its paces. I used a mouse for the first time, did my first CAD drawings on it and through it all, never complained about swapping disks.
The bombs were never something you wanted to run into and we figured out that the number of bombs meant something, but never quite figured it out. We were too busy hitting reset to get another game going.
Favourite games: Barbarian (frustrating), Championship Wrestling, Defender of the Crown, Elite (awesome score), Flight Simulator II and too many to remember.
Amiga 500: Guru Meditation

Seeing as I was so broke, I never bought a monitor (too expensive), but instead had a box that would convert the signal to plain old NTSC video, so you could plug it into any TV set. I got the RAM upgrade when I first bought it, bumping it from 512KB to a whopping 1MB. Eventually I got it modded to 8 MB of RAM, with a PAL/NTSC toggle on the back and ROM 2.0 (op from 1.3). I didn't realize that some of my favourite games didnt support 2.0... Oh well.
Favourite games: Dungeon Master, Time Bandits (a little-known little gem of a game), Powermonger (an RTS that was far, far ahead of its time), Dune II (need I say more?), Populous, Zoids, Monkey Island (!), Civilization, Empire (just such a great game, ask my bro), Pirates, Airball (surprisingly, not a sports game but a clever isometric dungeon-style platformer)
What is your favourite error message/screen? While you're considering that question, I invite you to read the Technologizer's 13 Greatest Error Messages of All Time.
As for me, I'm going back to coding.

Thanks. Saved my life.
My pleasure, Gupreet. I would have been up the creek had I not found a posting on this issue. Come back anytime!
Thanks... This helped me out!
My pleasure, Max. This bug certainly threw me for a loop when I hit up against it!