newbie question

Eric Jacobs none at none
Tue Apr 18 01:44:09 CEST 2000

In article <wbHK4.2614$Za1.38989 at>,
"Fredrik Lundh" <effbot at> wrote:
> Arint‚ <jamarijr at> wrote:
>> If i PyErr_SetString(PyExc_TypeError,"Invalid command value for IOCTL");
>> in my c/c++ program, how would python script get that error string?
> return NULL to the interpreter.  do *not* return
> a python value.

That, and then do something like

except TypeError, exc
     msg = exc.args[0]

in Python. I think that's what you were looking for?

More information about the Python-list mailing list