some problems
Luca Delucchi <[email protected]> Tue, 31 Mar 2015 16:32:57 +0200
| Newsgroups | gmane.comp.python.pyro |
|---|---|
| Message-ID | <CAK4m-3wQ8++zdvfcndDW5ZT__CnoyUDHMRa0QWBbQSE+LrSHcA@mail.gmail.com> |
Hi everybody,
I'm starting to work with Pyro4, I created some script to initialize
the servers using something like
def main():
gdalconvert_stem = convertGDAL()
Pyro4.Daemon.serveSimple({gdalconvert_stem: "stem.gdalconvert"},
host='10.234.1.190',
port=9092, ns=True)
if __name__ == "__main__":
main()
In the client side I use
cgdal = Pyro4.Proxy("PYRONAME:stem.gdalconvert")
cgdal.initialize(['/incoming/lucadelu/data/S2-8_lidar',
'/incoming/lucadelu/data/S2-8'], '/incoming/lucadelu/test.tif')
but If I pass also the last parameter of the function I got a problem
cgdal.initialize(['/incoming/lucadelu/data/S2-8_lidar',
'/incoming/lucadelu/data/S2-8'], '/incoming/lucadelu/test.tif',
'GTIFF')
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-12-43d08be34778> in <module>()
----> 1 cgdal.initialize(['/incoming/lucadelu/data/S2-8_lidar',
'/incoming/lucadelu/data/S2-8'], '/incoming/lucadelu/test.tif',
'GTIFF')
/usr/local/lib/python2.7/dist-packages/Pyro4/core.pyc in
__call__(self, *args, **kwargs)
167
168 def __call__(self, *args, **kwargs):
--> 169 return self.__send(self.__name, args, kwargs)
170
171
/usr/local/lib/python2.7/dist-packages/Pyro4/core.pyc in
_pyroInvoke(self, methodname, vargs, kwargs, flags, objectId)
396 if sys.platform == "cli":
397
util.fixIronPythonExceptionForPickle(data, False)
--> 398 raise data
399 else:
400 return data
TypeError: in method 'GetDriverByName', argument 1 of type 'char const *'
It seems that Pyro is doing some magic :-)
I have a similar problem with another server, I pass to the object a
list of strings but only the first is read by the class.
Any idea how to solve these problems?
Thanks a lot
--
ciao
Luca
http://gis.cri.fmach.it/delucchi/
www.lucadelu.org
------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the
conversation now. http://goparallel.sourceforge.net/