Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/pydefix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include <pybind11/stl.h> // For STL vectors and containers
#include <string>
#include <vector>
#include <csignal>
#include "idefix.hpp"
#include "dataBlock.hpp"
#include "dataBlockHost.hpp"
Expand Down Expand Up @@ -278,6 +279,7 @@ Pydefix::Pydefix(Input &input) {
idfx::cout << "Pydefix: start Python interpreter." << std::endl;

py::initialize_interpreter();
std::signal(SIGINT, SIG_DFL); // restore "terminate on Ctrl-C" signal handler
py::exec("import sys; print(f'Pydefix: Python Version: {sys.version}')");
py::exec("print(f'Pydefix: Executable Path: {sys.executable}')");
py::exec("print(f'Pydefix: Sys Path: {sys.path}')");
Expand Down
Loading