move back to misc.py as a wrapper