adding debug printing