Add more logging in debug