[omniORB] Problem with embedded Python

Andrew Midson a.midson at optimus2020.com
Mon Jan 5 12:32:11 GMT 2004


Hi

I am having a problem running Python scripts using omniORBpy (version 2.3),
and hope that someone can shed some light on this for me.

We have Python 2.2 embedded in a C++ application. Python is initialised when
the application starts and then, for each script run from the application,
an interpreter is created, the script is run and the interpreter is
destroyed. We can use ominORBpy in scripts run from this application as long
as we only run one such script. If a second omniORBpy script is run without
closing the application and restarting it, we get the following import
error:

ImportError: No module named omni_func

I have tried this using a script which consists only of the following line:

from omniORB import CORBA

but the error still occurs.

Previously the C++ application initialised Python prior to each script being
run and then finalised it when the script terminated. When run like this we
could run multiple omniORBpy scripts with no problems. Unfortunately we have
had to change to the new way of running the scripts as there were problems
with COM integration using the old method.

I hope that I have managed to explain the problem correctly and offer my
thanks in advance for any assistance that you can give me.

Regards

Andrew Midson

Optimus, The Management System for the Printing Industry
Optichrome Computer Systems Ltd.
Maybury Road, Woking, United Kingdom
UK: Tel: +44 1483 740233 Fax: +44 1483 760644
mailto:a.midson at optichrome.com http://www.optimus2020.com
On the Map:
http://www.streetmap.co.uk/streetmap.dll?G2M?X=501363&Y=159238&A=Y&Z=2

This is an e-mail from Optichrome Computer Systems Limited. The contents of
this e-mail are intended only for the named recipient and may be privileged
or confidential. If you are not the intended recipient please notify us
immediately




More information about the omniORB-list mailing list