chenzhengda opened a new issue, #2559:
URL: https://github.com/apache/brpc/issues/2559

   **Describe the bug (描述bug)**
   
   When I use brpc and pybind embed simultaneously and import numpy, the 
program gets stuck. However, it returns to normal once I remove the include for 
the brpc header file.
   
   **To Reproduce (复现方法)**
   
   ```
   #include <brpc/server.h>
   #include <pybind11/embed.h>
   #include <iostream>
   
   namespace py = pybind11;
   
   int main() {
       py::scoped_interpreter guard{};
   
       auto sys = py::module_::import("sys");
       std::cout << "Python version: " << 
sys.attr("version").cast<std::string>() << std::endl;
   
       // auto np = py::module_::import("numpy");
       // std::cout << "Numpy version: " << 
np.attr("__version__").cast<std::string>() << std::endl;
   
       return 0;
   }
   ```
   
   **Expected behavior (期望行为)**
   
   
   **Versions (各种版本)**
   OS:
   Compiler:
   brpc:
   protobuf:
   
   **Additional context/screenshots (更多上下文/截图)**
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@brpc.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@brpc.apache.org
For additional commands, e-mail: dev-h...@brpc.apache.org

Reply via email to