Some debug logging could be really valuable here later I think.