Add some more debug logging to catch that annoying bug.