Closed mkolin closed 2 years ago
The change was with the choice of methods returning std::string
to return the actual object and not convert them to Python str
objects. The motivation is that for Python3, this requires a decision on which unicode encoding to use. In most cases, std::string
is a drop-in replacement for str
, but in __repr__
and __str__
Python actually does a type check, hence failure.
Now fixed in repo and tests added to prevent future breakage.
Released with 2.4.0 and its dependencies.
In cppyy 2.3.0 you can no longer have a
__str__
or__repr__
that return astd::string
. I'm not sure when this changed. Returning a const char* works.