Unverified Commit 7331d381 authored by Shane Loretz's avatar Shane Loretz Committed by GitHub
Browse files

Raise codec errors when casting to std::string (#2903)



* Raise codec errors when casting to std::string

Allow the codec's exception to be raised instead of RuntimeError when
casting from py::str to std::string.

PY2 allows ucs surrogates in UTF-8 conversion

Signed-off-by: default avatarShane Loretz <sloretz@openrobotics.org>
Signed-off-by: default avatarShane Loretz <sloretz@osrfoundation.org>

* Attempt to fix py2 error

* Revert all unicode literals

* Fixed

Co-authored-by: default avatarAaron Gokaslan <skylion.aaron@gmail.com>
parent aca6c3ba
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment