Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Python 3: fix AnsibleError formatting
If you convert the error string to bytes and embed it inside another error string, you get Prefix: b'Embedded\nerror\nstring' which is not what we want. But we also don't want Unicode in error messages causing unexpected UnicodeEncodeErrors when on Python 2. So let's convert the error message into the native string type (bytes on Python 2, unicode on Python 3).
- Loading branch information