, Robert Kern wrote:
> On 5/3/11 9:28 PM, Stefan Kuzminski wrote:
>
>> closer I think
>>
>> 1) I changed tp_name to be 'observation.MV' ( module is named
>> observation.c )
>> and now I get a new error..
>>
>> PicklingError: Can't pickle : i
bservation(void) {
PyObject *m;
m = Py_InitModule("observation", observation_methods);
Py_INCREF(&PyMV_Type);
PyModule_AddObject(m, "MV", (PyObject *)&PyMV_Type);
}
thx,
S
On Tue, May 3, 2011 at 6:05 PM, Robert Kern wrote:
> On 5/3/11 4:34 PM, Stefan Kuzm
Thanks for the clues, I made a modification so that reduce returns this..
return Py_BuildValue("O(O)", Py_TYPE(self), PyTuple_New(0), Py_None,
Py_None, Py_None );
and now I get this different error when trying to pickle the type..
--
Hi all,
I have an extension type written in C, but I cannot get it to pickle, any
insights would be greatly appreciated.
I see in the docs that I should define a __reduce__ method and that does get
called, but I don't know specifically the type of the 'callable object' that
should be the first th