
The previous version returned a byte string, which caused errors on Python 3. I borrowed the fix from [1]. Change-Id: If89a3808271756925708e5f48f4a9726b5e25aec 1: https://git.openstack.org/cgit/openstack/cinder/commit/?id=9dc4c8704eef2e48fbae992db094be7ac91f8c6c