Hi !
I need to import a module and create an instance
of a class from that module (in C).
import mod
o = mod.klass()
(mod.klass is a subclass of tuple)
When I receive a class object from the module..
module = PyImport_ImportModule("mod")
cls = PyObject_GetAttrString(module, "klass")
..it fail
Hi !
I need to import a module and create an instance
of a class from that module (in C).
import mod
o = mod.klass()
(mod.klass is a subclass of tuple)
When I receive a class object from the module..
module = PyImport_ImportModule("mod")
cls = PyObject_GetAttrString(module, "klass")
..it fail