diff --git a/wrapping/python/NxPythonEmbed/NxPythonEmbed/NxPythonEmbed.hpp b/wrapping/python/NxPythonEmbed/NxPythonEmbed/NxPythonEmbed.hpp index 723a227684..ef774df1e6 100644 --- a/wrapping/python/NxPythonEmbed/NxPythonEmbed/NxPythonEmbed.hpp +++ b/wrapping/python/NxPythonEmbed/NxPythonEmbed/NxPythonEmbed.hpp @@ -308,7 +308,7 @@ inline std::vector LoadPythonPlugins(const std::set& p inline py::module_ GetImportlibMetadata() { auto sys = py::module_::import("sys"); - if(sys.attr("version_info").attr("__lt__")(py::make_tuple(3, 10))) + if(sys.attr("version_info").attr("__lt__")(py::make_tuple(3, 10)).cast()) { return py::module_::import("importlib_metadata"); }