more fixes and print statements