if six.PY2 and 'rest_cherrypy' in opts:
        # CherryPy is not unicode-compatible
        opts['rest_cherrypy'] = salt.utils.data.encode(opts['rest_cherrypy'])