change print into a warning