Doesn't seem to be related to 4.0.6... it's what I use, and the spy version is the exact one posted here:
http://forums.digitalpoint.com/spy.php
Do you have any sort of mod that might delete posts from the post table? Like something that might delete one and merge it into another post automatically? That could cause problems because by the time the spy outputs it, the postid no longer exists in the post table.