Actually, you know, I'm getting several situations where that comparision is failing, but if I explicitely do foo.id = blah.id it works. Looks like a bug. It seems to occur when I a foreign key lookup like:
if foo.get_blah() == myBlah: # doesn't always work ... while if foo.get_blah().id == myBlah.id: # works (Now I have to read the website again to see what the bug submission process is)