class problem with Embedded Python

Ing Giuseppe Monteleone info at ing-monteleone.com
Mon Mar 8 16:21:17 EST 2004


I Have a problem with embedded python: the interpeter work and i can call my
object. In other word the code

import geppo
geppo.boxwrite("test")

where geppo is my own module, work well, but when i try to define a class
like this

import geppo
class pippo:
    pass
geppo.boxwrite("test")

the C function PyRun_SimpleString give me a ret value < 0, an error.
Moreover when I ty to use an arimethic function I get a memory fault

import geppo
v = 3+3
geppo.boxwrite(v)

that code generate a memory fault.

Some one can help me ?

Thanks
In Giuseppe Monteleone







More information about the Python-list mailing list