more debug prints added in debug mode