Stephane BONNIEZ
2009-05-26 22:43:59 UTC
Hello,
I'm experiencing problems with OmniPy which seem to boil down to the
following test case.
The problem could be reproduced with both Python 2.4 and 2.6 and with
OmniORB 4.1.2 and 4.1.3.
My IDL looks like this:
module valuetypestest {
valuetype Type1 {
// Empty
};
valuetype Type2 {
// Empty too
};
valuetype CompositeType {
public Type1 obj1;
public Type2 obj2;
};
interface TestService {
oneway void doSomething(in CompositeType param);
};
};
I have a server started, exposing TestService, and I try to call it, so I
instantiate a CompositeType. That's where I get into trouble. If either
obj1 or obj2 is left to None, everything goes all right but if they both
have a not-None value, the client crashes with the following error message:
omniORB: Assertion failed. This indicates a bug in the application
using omniORB, or maybe in omniORB itself.
file: cdrValueChunkStream.cc
line: 286
info: *endp == -(pd_nestLevel + 1)
omniORB: Unexpected C++ exception during Python invocation.
This application has requested the Runtime to terminate it in an
unusual way.
Please contact the application's support team for more information.
The client code is as follows:
import sys
from omniORB import CORBA
import valuetypestest
orb = CORBA.ORB_init(sys.argv, CORBA.ORB_ID)
poa = orb.resolve_initial_references("RootPOA")
obj = orb.string_to_object(sys.argv[1])
server = obj._narrow(valuetypestest.TestService)
testParam = valuetypestest.CompositeType()
testParam.obj1 = valuetypestest.Type1()
testParam.obj2 = valuetypestest.Type2()
server.doSomething(testParam)
With -ORBtraceLevel 25 I noticed this right before the failed assertion:
omniORB: Create Python output value indirection tracker
omniORB: Start output value header.
omniORB: Start writing chunked value body. Nest level = 1.
omniORB: Start output value header.
omniORB: Start writing chunked value body. Nest level = 2.
-> omniORB: End writing chunked value. Nest level = 2.
omniORB: Start output value header.
omniORB: Start writing chunked value body. Nest level = 2.
-> omniORB: End writing nested chunked value. Nest level = 2.
However, I'm stuck here. Can you help me out with this ?
Thanks in advance,
Stephane
PS : I attached the complete source code.
(See attached file: corbaserver.py)(See attached file: corbaclient.py)(See
attached file: valuetypetest.idl)
*************************************************************************
This message and any attachments (the "message") are confidential, intended solely for the addressee(s), and may contain legally privileged information.
Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration.
Neither SOCIETE GENERALE nor any of its subsidiaries or affiliates shall be liable for the message if altered, changed or
falsified.
************
Ce message et toutes les pieces jointes (ci-apres le "message") sont confidentiels et susceptibles de contenir des informations couvertes
par le secret professionnel.
Ce message est etabli a l'intention exclusive de ses destinataires. Toute utilisation ou diffusion non autorisee est interdite.
Tout message electronique est susceptible d'alteration.
La SOCIETE GENERALE et ses filiales declinent toute responsabilite au titre de ce message s'il a ete altere, deforme ou falsifie.
*************************************************************************
-------------- next part --------------
A non-text attachment was scrubbed...
Name: corbaserver.py
Type: application/octet-stream
Size: 470 bytes
Desc: not available
Url : http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20090526/1dfedcf9/corbaserver.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: corbaclient.py
Type: application/octet-stream
Size: 1048 bytes
Desc: not available
Url : http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20090526/1dfedcf9/corbaclient.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: valuetypetest.idl
Type: application/octet-stream
Size: 307 bytes
Desc: not available
Url : http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20090526/1dfedcf9/valuetypetest.obj
I'm experiencing problems with OmniPy which seem to boil down to the
following test case.
The problem could be reproduced with both Python 2.4 and 2.6 and with
OmniORB 4.1.2 and 4.1.3.
My IDL looks like this:
module valuetypestest {
valuetype Type1 {
// Empty
};
valuetype Type2 {
// Empty too
};
valuetype CompositeType {
public Type1 obj1;
public Type2 obj2;
};
interface TestService {
oneway void doSomething(in CompositeType param);
};
};
I have a server started, exposing TestService, and I try to call it, so I
instantiate a CompositeType. That's where I get into trouble. If either
obj1 or obj2 is left to None, everything goes all right but if they both
have a not-None value, the client crashes with the following error message:
omniORB: Assertion failed. This indicates a bug in the application
using omniORB, or maybe in omniORB itself.
file: cdrValueChunkStream.cc
line: 286
info: *endp == -(pd_nestLevel + 1)
omniORB: Unexpected C++ exception during Python invocation.
This application has requested the Runtime to terminate it in an
unusual way.
Please contact the application's support team for more information.
The client code is as follows:
import sys
from omniORB import CORBA
import valuetypestest
orb = CORBA.ORB_init(sys.argv, CORBA.ORB_ID)
poa = orb.resolve_initial_references("RootPOA")
obj = orb.string_to_object(sys.argv[1])
server = obj._narrow(valuetypestest.TestService)
testParam = valuetypestest.CompositeType()
testParam.obj1 = valuetypestest.Type1()
testParam.obj2 = valuetypestest.Type2()
server.doSomething(testParam)
With -ORBtraceLevel 25 I noticed this right before the failed assertion:
omniORB: Create Python output value indirection tracker
omniORB: Start output value header.
omniORB: Start writing chunked value body. Nest level = 1.
omniORB: Start output value header.
omniORB: Start writing chunked value body. Nest level = 2.
-> omniORB: End writing chunked value. Nest level = 2.
omniORB: Start output value header.
omniORB: Start writing chunked value body. Nest level = 2.
-> omniORB: End writing nested chunked value. Nest level = 2.
However, I'm stuck here. Can you help me out with this ?
Thanks in advance,
Stephane
PS : I attached the complete source code.
(See attached file: corbaserver.py)(See attached file: corbaclient.py)(See
attached file: valuetypetest.idl)
*************************************************************************
This message and any attachments (the "message") are confidential, intended solely for the addressee(s), and may contain legally privileged information.
Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration.
Neither SOCIETE GENERALE nor any of its subsidiaries or affiliates shall be liable for the message if altered, changed or
falsified.
************
Ce message et toutes les pieces jointes (ci-apres le "message") sont confidentiels et susceptibles de contenir des informations couvertes
par le secret professionnel.
Ce message est etabli a l'intention exclusive de ses destinataires. Toute utilisation ou diffusion non autorisee est interdite.
Tout message electronique est susceptible d'alteration.
La SOCIETE GENERALE et ses filiales declinent toute responsabilite au titre de ce message s'il a ete altere, deforme ou falsifie.
*************************************************************************
-------------- next part --------------
A non-text attachment was scrubbed...
Name: corbaserver.py
Type: application/octet-stream
Size: 470 bytes
Desc: not available
Url : http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20090526/1dfedcf9/corbaserver.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: corbaclient.py
Type: application/octet-stream
Size: 1048 bytes
Desc: not available
Url : http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20090526/1dfedcf9/corbaclient.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: valuetypetest.idl
Type: application/octet-stream
Size: 307 bytes
Desc: not available
Url : http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20090526/1dfedcf9/valuetypetest.obj