-
Module py::class_<rclcpp::Node, std::shared_ptr<rclcpp::Node>>(m, "Node")
.def(py::init<const std::string&, py::arg("name")); Module
However, calling that function, I get a
Note, that the function signature doesn't mention the wrapped typename If I compile both modules against the same pybind11 version (both using the smart_holder branch), it works as expected. In the past, it was possible to intermix modules compiled with different pybind11 versions. The only thing to consider was that both versions share the same |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
(Sorry for the long delay responding. I'm just back from a vacation.) I'm not sure what was changed in what version. The first thing that comes to mind is this bug fix: https://github.com/pybind/pybind11/pull/5026/files Could that explain your observation? If that's it and it worked before for you: I believe it only worked by luck. But I never spent the time to fully reason out for myself when and why the |
Beta Was this translation helpful? Give feedback.
(Sorry for the long delay responding. I'm just back from a vacation.)
I'm not sure what was changed in what version.
The first thing that comes to mind is this bug fix:
https://github.com/pybind/pybind11/pull/5026/files
Could that explain your observation?
If that's it and it worked before for you: I believe it only worked by luck. But I never spent the time to fully reason out for myself when and why the
"_sh_def"
should be inserted. My main thought was: better safe than sorry.