From aecd76594f72eb8a097b061b06d233d4225bcc1f Mon Sep 17 00:00:00 2001 From: Ian Chua Date: Tue, 20 Oct 2026 18:32:50 +0800 Subject: [PATCH] fix: Python thread audit shim kwargs forwarding --- src/slic3r/plugin/PythonPluginBridge.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/slic3r/plugin/PythonPluginBridge.cpp b/src/slic3r/plugin/PythonPluginBridge.cpp index 60ecf8bfe7..2cb40f49b0 100644 --- a/src/slic3r/plugin/PythonPluginBridge.cpp +++ b/src/slic3r/plugin/PythonPluginBridge.cpp @@ -636,7 +636,7 @@ void install_python_thread_audit_shim() const std::string plugin_key = PluginAuditManager::instance().current_plugin(); if (plugin_key.empty()) { // Not called from a plugin: preserve the stock implementation untouched. - return original(function, args, kwargs); + return kwargs.is_none() ? original(function, args) : original(function, args, kwargs); } const std::string capability = PluginAuditManager::instance().current_capability(); @@ -648,7 +648,7 @@ void install_python_thread_audit_shim() throw py::error_already_set(); return py::reinterpret_steal(result); }); - return original(guarded, args, kwargs); + return kwargs.is_none() ? original(guarded, args) : original(guarded, args, kwargs); }, py::arg("function"), py::arg("args"), py::arg("kwargs") = py::none());