From e60f2159e196b28f51c2e4bc326d78256c53f9a6 Mon Sep 17 00:00:00 2001 From: John Colvin Date: Wed, 16 Jul 2025 14:17:02 +0000 Subject: [PATCH] fix: Prevent python plugins from intercepting kill sig So the process actually terminates on ctrl+c --- src/lib_python_interop/python_interop/plugin_manager.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/lib_python_interop/python_interop/plugin_manager.cpp b/src/lib_python_interop/python_interop/plugin_manager.cpp index f227cda80..c4864a339 100644 --- a/src/lib_python_interop/python_interop/plugin_manager.cpp +++ b/src/lib_python_interop/python_interop/plugin_manager.cpp @@ -105,6 +105,8 @@ struct __attribute__((visibility("hidden"))) PluginManager_Impl { sd.import("bybit_md_provider"); sd.import("bybit_execution_gateway"); py::gil_scoped_release gil_rel; + // Don't let python handle the signals (otherwise it'll hang on ctrl+c) + std::signal(SIGINT, SIG_DFL); Stopwatch sw; int n = 0; while (keep_going) {