fix pyflakes reports in detect.py and hpacucli.py
detect.py: use sys.stderr instead of print to be coherent