added some logging.debug statements