From: kishor s. <kis...@gm...> - 2016-04-28 18:02:15
|
Sorry I hit enter too soon. >You might like to add a bug report to tack this issue. If you have a patch to add __module__ I’ll review and add. I kind of figured out the issue. Issue is we are using PyCFunction_New to register the modules in the method. If we replace PyCFunction_New with PyCFunction_NewEx it solves the problem with module level function e.g. PyObject* func = PyCFunction_NewEx(&method_def->ext_meth_def, new_reference_to(args), PyString_FromString(m_module_name.c_str()) I am not sure about how to fix problem for function in the extension class. Any help/pointers? On Thu, Apr 28, 2016 at 11:29 PM, kishor sharma <kis...@gm...> wrote: > >You might like to add a bug report to tack this issue. If you have a > patch to add __module__ I’ll review and add. > > I kind of figured out the issue. Issue is we are using PyCFunction_New to > register the modules in the method. If we replace PyCFunction_New with > PyCFunction_NewEx it solves the problem with module level function > > e.g. PyObject* func = PyCFunction_NewEx( > > > |