You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for reporting. It would indeed be nice for that to work.
The Python API of OpenQL is built with SWIG which makes it possible to call the C++ functions from within Python.
C++ has obviously no knowledge of pathlib. And it seems that there is no implicit conversion to string done before calling the C++ method.
I would assume that doing the conversion yourself (with str(...)) works just fine?
Yes, conversion the str works fine. But this is something users will bump into, as pathlib is becoming more the standard, so it would be nice if openql could support this. Perhaps swig has options for this, but I have not checked
The OpenQL
set
andset_option
methods do not work with pathlib duck typing for str. A minimal example:results in
TypeError: in method 'set_option', argument 2 of type 'std::string const &'
The text was updated successfully, but these errors were encountered: