]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
Avoid using import CORBA
authorGilles DAVID <gilles-g.david@edf.fr>
Thu, 27 Jul 2017 15:23:04 +0000 (17:23 +0200)
committerGilles DAVID <gilles-g.david@edf.fr>
Thu, 27 Jul 2017 15:23:06 +0000 (17:23 +0200)
Prefer: "from omniORB import CORBA"

bin/runConsole.py
src/Communication_SWIG/libSALOME_Comm.i
src/LifeCycleCORBA_SWIG/TestLifeCycleCORBA.py

index fe62b6895225289254a9c5fb1e1dd7c95bdffefe..9639291f7f182d730a2e301f360dd7e40c74199d 100644 (file)
@@ -131,7 +131,7 @@ def __get_running_session(requested_port=None, lastInstanceByDefault=False):
   return host, port, filename
 #
 
-import CORBA
+from omniORB import CORBA
 import CosNaming
 import orbmodule
 
index 9a3c0211451220599801269c2656b515e22d5388..7681ec35fe9ac96c4086d12abb8435a3caeeb358 100644 (file)
@@ -36,7 +36,7 @@
 {
   PyObject* pdict = PyDict_New();
   PyDict_SetItemString(pdict, "__builtins__", PyEval_GetBuiltins());
-  PyRun_String("import CORBA", Py_single_input, pdict, pdict);
+  PyRun_String("from omniORB import CORBA", Py_single_input, pdict, pdict);
  
   PyRun_String("o = CORBA.ORB_init([''], CORBA.ORB_ID);", Py_single_input,
                    pdict, pdict);
@@ -66,7 +66,7 @@
 {
   PyObject* pdict = PyDict_New();
   PyDict_SetItemString(pdict, "__builtins__", PyEval_GetBuiltins());
-  PyRun_String("import CORBA", Py_single_input, pdict, pdict);
+  PyRun_String("from omniORB import CORBA", Py_single_input, pdict, pdict);
  
   PyRun_String("o = CORBA.ORB_init([''], CORBA.ORB_ID);", Py_single_input,
                    pdict, pdict);
@@ -96,7 +96,7 @@
 {  
    PyObject* pdict = PyDict_New();
    PyDict_SetItemString(pdict, "__builtins__", PyEval_GetBuiltins());
-   PyRun_String("import CORBA", Py_single_input, pdict, pdict);
+   PyRun_String("from omniORB import CORBA", Py_single_input, pdict, pdict);
    PyRun_String("o = CORBA.ORB_init([''], CORBA.ORB_ID);", Py_single_input,
                    pdict, pdict);
    PyObject* orb = PyDict_GetItemString(pdict, "o");
 {  
    PyObject* pdict = PyDict_New();
    PyDict_SetItemString(pdict, "__builtins__", PyEval_GetBuiltins());
-   PyRun_String("import CORBA", Py_single_input, pdict, pdict);
+   PyRun_String("from omniORB import CORBA", Py_single_input, pdict, pdict);
    PyRun_String("o = CORBA.ORB_init([''], CORBA.ORB_ID);", Py_single_input,
                    pdict, pdict);
    PyObject* orb = PyDict_GetItemString(pdict, "o");
index 878797b5b06a387ec47aeb27e96c98a59afdda19..b0800d53d335676ae4d644d1bc877e5239c00f94 100644 (file)
@@ -47,7 +47,7 @@ except :
     print 'lcc.FindOrLoad_Component("FactoryServer","SalomeTestComponent") failed'
 
 import sys
-import CORBA
+from omniORB import CORBA
 import CosNaming
 orb = CORBA.ORB_init(sys.argv, CORBA.ORB_ID)
 obj = orb.resolve_initial_references("NameService")