we should use `logging.warning` etc. instead of calling print directly