f



Python to Python communication

Hello,

I have a group of Python programms which I want to teach to "talk to each 
other".

All run on Windows, on the same computer or in the same intranet. 
Security of communication is not an issue (encryption on lower level 
protocols / intra computer communication). Partially these programs are 
using wxPython.

It is important that the communcation is "only an added feature", I am 
not willing to spend big memory / computing ressources on it.


So I googled and came up with at least the following opportunities:

XMLRPC - quite "simple" to implement within python, contained in my 
favourite web framework Quixote / medusa

SOAP - around the same amount of work as XMLRPC

----> these two are fully buzzword compatible to enterprise communication 
needs. But are they really lightwight and needed?


Banana - within the twisted framework. Is described as high performance 
with very litte ressources. From my scanning of twisted it is meanwhile 
possible to integrate it within wxPython and you only need to sell the 
soul of your firstborn for it; but I got the impression twisted rather 
needs a total commitment than a "I just need some banana, man"

pyro - Python Remote Objects. Irmen de Jong has a "get Firefox" icon on 
it's page and he plays with the name "pyro", which makes a good 
impression. It looks rather "ripe", but: he is talking about "pyro 4.0" 
which will be incompatible with pyro 3.4 and a total redesign. That makes 
me shudder.

COM / DCOM. From our favourite software company, available mainly within 
windows. Wrapped excellently with pywin32 ... but needs some seriuos 
type-mangeling to get through and around 2 Gig of Browser Cache to read 
all the MSDN documentation, which is quite C-ish.

socket / select. Within the standard lib. Does not look to hard to get to 
work, working samples included in the nutshell.

----

so, I am stranded ... and ask C.L.P. for recommendations.

What library have you used and would recommend?

Harald
0
10/11/2004 12:40:07 PM
comp.lang.python 77058 articles. 6 followers. Post Follow

9 Replies
1802 Views

Similar Articles

[PageSpeed] 17

hi,

> XMLRPC - quite "simple" to implement within python, contained in my
> favourite web framework Quixote / medusa
> 
> SOAP - around the same amount of work as XMLRPC
> 
> ----> these two are fully buzzword compatible to enterprise communication
> needs. But are they really lightwight and needed?

Unless you don't need the connectivity to other non-python apps that depend
on using one of them, stay clear of those two. They are pretty slow,
primitive in the sense that all they give you is a stateless C-api-like
calls and by far not as mature as say corba. And last time I checked, the
SOAP-support in python was far from beeing complete. And that checking of
mine hasn't been too long ago.

> 
> Banana - within the twisted framework. Is described as high performance
> with very litte ressources. From my scanning of twisted it is meanwhile
> possible to integrate it within wxPython and you only need to sell the
> soul of your firstborn for it; but I got the impression twisted rather
> needs a total commitment than a "I just need some banana, man"
> pyro - Python Remote Objects. Irmen de Jong has a "get Firefox" icon on
> it's page and he plays with the name "pyro", which makes a good
> impression. It looks rather "ripe", but: he is talking about "pyro 4.0"
> which will be incompatible with pyro 3.4 and a total redesign. That makes
> me shudder.

Don't used those two, but if I had a similar situation to yours (namely no
non-python-apps), I'd certainly give pyro a try.

> COM / DCOM. From our favourite software company, available mainly within
> windows. Wrapped excellently with pywin32 ... but needs some seriuos
> type-mangeling to get through and around 2 Gig of Browser Cache to read
> all the MSDN documentation, which is quite C-ish.

I use Linux, so I won't comment on that.

> socket / select. Within the standard lib. Does not look to hard to get to
> work, working samples included in the nutshell.

Been down that road - but while its quick to start, it nearly as fast gets
tedious as your requirements develop - usually, you end up with your own
xmlrpc-style implementation. Better skip that.

I personally have very good expiriences with corba - omniORBpy, to be
precise. Don't know how well that runs on windows, though. But on *nix, it
certainly saved my day more than once.

Regards,

Diez
0
10/11/2004 12:51:43 PM
On Mon, 11 Oct 2004 12:40:07 +0000 (UTC), Harald Massa  
<cpl.19.ghum@spamgourmet.com> wrote:

> Hello,
>
> I have a group of Python programms which I want to teach to "talk to each
> other".
>
> All run on Windows, on the same computer or in the same intranet.
> Security of communication is not an issue (encryption on lower level
> protocols / intra computer communication). Partially these programs are
> using wxPython.
>
> It is important that the communcation is "only an added feature", I am
> not willing to spend big memory / computing ressources on it.
>

[SNIP]

>
> pyro - Python Remote Objects. Irmen de Jong has a "get Firefox" icon on
> it's page and he plays with the name "pyro", which makes a good
> impression. It looks rather "ripe", but: he is talking about "pyro 4.0"
> which will be incompatible with pyro 3.4 and a total redesign. That makes
> me shudder.
>

[SNIP]

> Harald


Harald,

I only have experience with Pyro, so am biased, but from your rather  
sketchy
description I think it would have the smallest impact (in terms of existing
code re-work) as it can simply be bolted on with the inclusion of a couple
of extra classes. At least that was my experience when I needed to get a  
couple
of python applications talking...

Just my tupence worth :-)

Martin



-- 
Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/

0
mfranklin1 (137)
10/11/2004 1:02:06 PM
Am Mon, 11 Oct 2004 12:40:07 +0000 schrieb Harald Massa:

> Hello,
> 
> I have a group of Python programms which I want to teach to "talk to each 
> other".
> 
> All run on Windows, on the same computer or in the same intranet. 
> Security of communication is not an issue (encryption on lower level 
> protocols / intra computer communication). Partially these programs are 
> using wxPython.

Hi,

Before choosing a framework (pyro, socket or other) you should know
how you want to communicate. 

The easiest is "client-server". There is one server and several
clients connect to it. 

Peer to peer: There is no central server. All can talk to each other.
The problem is: How to find the other? If there are on one computer
this is easy: Just write files to a directory all processes know.
But if you want to talk to other computers, you need to know their
IP addresses.

For the communication UDP, TCP or HTTP can be used. I would not
use HTTP (XMLRPC or SOAP) if you don't need to. UDP is stateless,
and can be used for broadcasts.

I would use pyro or the socket module.

HTH,
 Thomas

0
guettli (230)
10/11/2004 1:58:44 PM
Harald Massa wrote:

 > I have a group of Python programs which I want
 > to teach to "talk to each other".

> What library have you used and would recommend?

I think this depends on what exactly the nature of
the "communication".Do you want to send data across or
functionality.

XMLRPC and pyro are about sharing behavior:
functions or methods.

If you need to keep a connection open and keep
exchanging raw data, then sockets might make more sense.

Istvan.
0
ialbert (222)
10/11/2004 3:21:24 PM
[Harald Massa]
>>I have a group of Python programms which I want to teach to "talk to each 
>>other".

[Thomas Guettler]
> Peer to peer: There is no central server. All can talk to each other.
> The problem is: How to find the other? If there are on one computer
> this is easy: Just write files to a directory all processes know.
> But if you want to talk to other computers, you need to know their
> IP addresses.

Or use a peer-to-peer library that has solved all of those problems already

http://www.python.org/other/spread/

regards,

-- 
alan kennedy
------------------------------------------------------
email alan:              http://xhaus.com/contact/alan
0
alanmk (319)
10/11/2004 3:34:57 PM
Harald Massa wrote:

> pyro - Python Remote Objects. Irmen de Jong has a "get Firefox" icon on 
> it's page and he plays with the name "pyro", which makes a good 
> impression.

Hey, thanks :)

> It looks rather "ripe", but: he is talking about "pyro 4.0" 
> which will be incompatible with pyro 3.4 and a total redesign. That makes 
> me shudder.

Pyro is "ripe"... version 3.0 was released Q4, 2002, so the 3.x
versions have been around and in active use for 2 years now.

I've been talking about Pyro 4.0 for a long time, but we haven't
even begun the real design of it. Partly because of lack of time,
partly because Pyro 3.x does its job so well (not my own words).

What is it that makes you shudder?
If you don't want to switch to Pyro 4.0 once (if??) it is released,
just continue using Pyro 3.x. I have no intentions of abandoning
the 3.x version: if there is an itch, or a bug, it will be addressed.


Regards,

Irmen de Jong
0
Irmen
10/11/2004 3:42:17 PM
A cheap solution for brainstorming: just output messages to files.

   p1/001.msg
   p2/002.msg
   ...etc...

Do some polling to pick up messages. This is very asynchronize and maybe  
useful for some communication pattern.
0
aurora00 (75)
10/11/2004 9:58:58 PM
Hello Irmen,

> Pyro is "ripe"... version 3.0 was released Q4, 2002, so the 3.x
> versions have been around and in active use for 2 years now.

That is really good information! Thank you. "active for 2 years" is 
rather "mature" then only "ripe" :)))

> I've been talking about Pyro 4.0 for a long time, but we haven't
> even begun the real design of it. 
> What is it that makes you shudder?

Really exactly that :))) I do not know you at all; as I said: your 
presentation, the documentation and the voices within c.l.p. give me a 
very positive feeling towards you and your software. So all my 
"shuddering" comes from this bits of information: "the author of a 
product thinks to further develop it a complete redesign - not a gradual 
upgrade - is necessary - so maybe I should wait for that" :)) And the 
fear, that new ideas will be postponed to the imaginary future version. 
(I tend do to such things with my own projects, too )

So I will give a very deep look at PyRo and spread... especially because 
I need that "peer to peer"

Thank you all for your support!

Harald

0
10/11/2004 10:34:20 PM
Alan Kennedy <alanmk@hotmail.com> wrote in

[Thomas Guettler]
>> Peer to peer: There is no central server. All can talk to each other.
>> The problem is: How to find the other? If there are on one computer

Yes, considering my challenge "peer to peer" would fit best 
>
> Or use a peer-to-peer library that has solved all of those problems
> already 
> 
> http://www.python.org/other/spread/

Yeah, spread looks beautifull from it's documentation. But I failed in 
setting up ... the python-module is prepared for spread 3.16.4, actual is 
3.17.2, which has total different librarynames to start with ... so 

python setup.py build --compiler=mingw32 fails badly when trying to link.

Has someone succeeded in doing a windows build for python 2.3.4 and spread 
3.17.2 ??? I would be very thankfull for a howto or a spread.pyd :)

Harald
0
10/11/2004 11:44:45 PM
Reply:

Similar Artilces:

python is a python
python is a python ...

Embedding Python in Python
Hi, I've been programming in Python for a couple of weeks now and am quite impressed with the language - it was very easy to learn (it actually reminds me a lot of programming in BASIC many many years ago - it's very fast to hack together a couple lines of code in interactive mode). I'm throwing together a simple little game (sort of a MUD-type thing) as my first 'big' project, and I thought it would be cool to be able to script the game in Python. Basically, I want to be able to type scripts in from within the game and attach them to objects, monsters, rooms, whatever. N...

Invoking Python from Python
Hi all, I have a need to create a Python script on the fly from another Python program and then execute the script so created. Do I need to invoke Python through os.spawnl or is there a better way? Thanks, -- John Am Tue, 08 Nov 2005 08:10:25 -0800 schrieb John Henry: > Hi all, > > I have a need to create a Python script on the fly from another Python > program and then execute the script so created. Do I need to invoke > Python through os.spawnl or is there a better way? Hi, creating source code with a script, is no good solution. Once I had to maintain lisp code w...

Python mascot? How about a Pythoneer?
I've been thinking that a good Python mascot might help in raising public awareness of Python. The problem with a snake as a mascot is that it is not anthropomorphic enough. An effective mascot has to have something approximating two arms, two legs, and a head, so that he can be put into various interesting situations and adventures. (At the very least, he has to be able to work a keyboard and a mouse!) Good examples can be found in some of the imaginative things that have been done with Linux's Tux. So a snake is out. So are Terry Gilliam's wonderful cartoons for the Flyin...

Python in the enterprise: "Python Slithers into Systems" / Why Python? (eweek 2007)
Last summers box office hit "snakes on a plane" was the unlikely story of a batch of snakes getting loose in flight on a 747. In what some might view as just as unlikely, ITA Software is using the Python language to empower its airline reservation system. Many computer language purists say that languages such as Java, C++ or C should be used for enterprise applications. However, ITA, a Cambridge, Mass., provider of airline IT software and services, is proving that dynamic languages such as Python can be rock-solid for enterprise work. Indeed, ITA in September 2006 announced an agreement with Montreal-based Air Canada, a subsidiary of ACE Aviation Holdings, to develop a new reservation management system for the airline. Air Canadas next- generation reservation system will include reservations, inventory control and seat availability, along with airport check-in and airport operations modules. Sean Menke, Air Canadas executive vice president and chief commercial officer, said the new system "will be a key instrument in Air Canadas strategy to maintain market leadership through product and customer differentiation. Moreover, it will provide unprecedented flexibility and significant cost savings." Leaving Legacy Behind Dan Kelley, director of application integration at ITA, said ITA will deliver the system to Air Canada next year, and it will be deployed across the entire Air Canada network, including reservation...

python QT or python-GTK
** All the posts found in google are old. I'm assuming new improvements have been made to both IDEs. ** Please correct me if I'm wrong, I'm a newbie. 1. Which one of them requires fewer lines to accomplish the same thing? from what I understand QT it's just like Borland J-Builder. Meaning, you want a button, you draw it, then you double-click on it, a window opens up and you type events and behavior. And with GTK, you just type everything. 2. Which one is cross platform? (Linux, MacOS, Windows,etc). 3. Which one has more widgets? 4. Which one is the easiest to pick up? I...

embedding python in python #3
Hi, anyone had any experiences in embedding python in python? I've tried to do this but it doesn't work. eval("from Tkinter import *") Thanks maurice Use exec. On Wed, Sep 29, 2004 at 09:23:28AM +0000, Maurice LING wrote: > Hi, > > anyone had any experiences in embedding python in python? > > I've tried to do this but it doesn't work. > > eval("from Tkinter import *") Maurice LING <mauriceling@acm.org> wrote in message news:<415a7f0b$1@news.unimelb.edu.au>... > Hi, > > anyone had any experiences in embeddi...

Subsets of Python implemented in Python
I don't understand why some parts of the Python language (or the Python standard library too) are implemented in C while some other parts are implemented in the Python language itself. For instance, lists and dictionnaries are implemented in C but sets are not. Wouldn't be better to implement all in C (for efficiency reasons for example) ? On Jul 17, 12:34=A0am, candide <cand...@free.invalid> wrote: > I don't understand why some parts of the Python language (or the Python > standard library too) are implemented in C while some other parts are > implem...

Using Python To Launch Python
Hello All, I have a situation where I can count on a Python installation being available on a system, but I can't count on it being a version of Python needed by my application. Since my application has it's own version of Python installed with it how should I use the system Python to launch the version of Python that launches my Application. Yes, this is a convoluted process, but not all Pythons are built the same :) Right now I am leaning towards using exec to start a new process, but I thought I would check to see if anyone else has had the need to perform a task similar to thi...

ActivePython or Python from Python.org
Hi everyone. I noticed that ActiveState has their own variation of Python and was curious if there's a benefit to choosing their version over the version offered via Python.org. Could someone lend some insight? Thanks, Rey... Rey Bango wrote: > Hi everyone. I noticed that ActiveState has their own variation of > Python and was curious if there's a benefit to choosing their version > over the version offered via Python.org. > > Could someone lend some insight? Here is some reasoning I wrote a while back: http://mail.python.org/pipermail/python-list/2007-July/447987...

How to run python without python
Is there a way to developing a script on linux and give it to someone on microsoft, so that they could run it on microsoft without installing python? Wayne ...

Python script to install python
I would like to have a python script that would download the most recent svn of python, configure, make, install and cleanup after itself. I am not replacing the python version I would be using to run the script. I was struggling to get this to work and I assume someone else has done it better. Any pointers? Thanks Vincent ...

python-list@python.org
Has anyone got a simple python script that will parse a linux mbox and create a large file to view . I need to write a python program the grabs mail from a standard linux mail folder and processes it to file to eventually be transfered to a database. Im having problems at the moment can someone post a exmaple or no if a similar script exists to hack. Not to good with Python and I have'nt got alot of time to get to grips with writing my own. Cheers Chuck ...

Embedding Python in Python #2
Anyone know a good way to embed python within python? Now before you tell me that's silly, let me explain what I'd like to do. I'd like to allow user-defined scriptable objects. I'd like to give them access to modify pieces of my classes. I'd like to disallow access to pretty much the rest of the modules. Any ideas/examples? -Robey You probably want something like this: globalDict = {} exec(stringOfPythonCodeFromUser, globalDict) globalDict is now the global namespace of whatever was in stringOfPythonCodeFromUser, so you can grab values from that and selectivly im...

Python from Smalltalk / Smalltalk from Python?
I am currently using a graphical package which is scripted with (integrated with) python. But I'd like to do my programming in smalltalk, thank you very much. How much of a hassle is it to connect python and smalltalk for this sort of thing? Anyone else done it? Is there a recommended approach? Tips? Suggestions? Pitfalls? (I have interfaced with C in the past, relatively painlessly, so I'm not a total newbie with this sort of thing) Thanks. pineapple.link@yahoo.com escreveu: > I am currently using a graphical package which is scripted with > (integrated with...

Python 3 is killing Python
--047d7bfceec297d37804fa7abe05 Content-Type: text/plain; charset=UTF-8 Somthing I came across in my travels through the ether: https://medium.com/@deliciousrobots/5d2ad703365d/ --047d7bfceec297d37804fa7abe05 Content-Type: text/html; charset=UTF-8 <div dir="ltr"><div>Somthing I came across in my travels through the ether:<br></div><div><br></div><a href="https://medium.com/@deliciousrobots/5d2ad703365d/" target="_blank">https://medium.com/@deliciousrobots/5d2ad703365d/</a><br> </div> ...

Python daemonisation with python-daemon
Hello there, I currently have a little project which involve the writing of a server that launch tasks when requested by the user (through a web interface for instance). I would like to turn my server script into a Linux/Unix daemon (launched at boot time by init, dunno if that matter) using the nice python-daemon package by Ben Finley et al (http://pypi.python.org/pypi/ python-daemon/). This package comes with a class DaemonRunner that seems to fit almost exactly my need but I still have some interrogation. My main class looks like the following: class SIGTERM_Received(Except...

python/python output buffers
Hi, I'm having a little problem while using python mode. I'm used to hit C-c C-c and have a Python Output buffer opened with the output. Now, on Ubuntu 7.10 and 8.04, C-c C-c sends to the Python buffer that is not raised in a window. I need to hit C-c C-z to see it. First of all I'm puzzled and would like to understand what makes the difference. I guess is some defaults that changed in the system configuration. What makes the difference between the two behaviors? Thanks in advance sandro *:-) sandro dentella a �crit : > Hi, > > I'm having a little proble...

Re: Python mascot? How about a Pythoneer?
Stephen Ferg <steve@ferg.org> wrote: > > I've been thinking that a good Python mascot might help in raising > public awareness of Python. > > The problem with a snake as a mascot is that it is not > anthropomorphic > enough....so a snake is out. > > So are Terry Gilliam's wonderful cartoons for the Flying Circus. > While wonderful, I just don't think they lend themselves to > mascot-hood. > > In that spirit, I propose the development of a figure representing > Python -- the Pythoneer. Given that Python users are traditionally ...

Python's and and Pythons or
I really like the logic that Pythons "or" is not only short-circuit but non-typed. So I can say y = override or default and y won't necc be True or False. If override boolean evaluates to True (which, for most classes, means not None) than y will be equal to override. Otherwise it will be equal to default. I have two questions --> Is there a handy name for this type of conditional (something as catchy as "short circuit or") and --> Is there a common idiom for taking advantage of the similar behavior of "and". The "override or def...

python 2 to python 3
I am using Wing101 v.5 and it is using Python2, but I want to make it = use Python3 instead because need Python3 for a uni lab. How do I = change it?= Audrey McFarlane wrote: > I am using Wing101 v.5 and it is using Python2, but I want to make it use > Python3 instead because need Python3 for a uni lab. How do I change it? I'm afraid I don't use Wing so I can't give a good answer, but I googled and found this: http://stackoverflow.com/questions/25318792/how-do-i-configure-wing101-to-run-python-3-3 It's not very helpful, but it might point you in th...

python-daemon for Python v3
Hi Community Is there ported to Python v3 python-daemon package? https://pypi.python.org/pypi/python-daemon/ i am afraid it is not as simple as correction of relative path input feature and except clauses in mentioned package. Thanks Asaf Asaf Las <roegltd@gmail.com> writes: > Is there ported to Python v3 python-daemon package? > > https://pypi.python.org/pypi/python-daemon/ Have a read through the archives for the ‘python-daemon-devel’ discussion forum <URL:http://lists.alioth.debian.org/mailman/listinfo/python-daemon-devel>, where we have ...

Repo/directory names (was Re: Python and IDEs [was Re: Python 3 is killing Python])
On Sun, Jul 20, 2014 at 10:41 AM, Tim Delaney <timothy.c.delaney@gmail.com> wrote: > On 20 July 2014 09:19, Chris Angelico <rosuav@gmail.com> wrote: >> >> That said, though, there are some projects so modest they don't >> require dedicated repositories. I have a repo called "shed" - it's a >> collection of random tools that I've put together, no more logical >> grouping exists. > > Agreed. I have a "utils" one - but I do like "shed" and think I'm going to > rename :) I first met tha...

Python
I have decided to learn a programming language and decided on Python. I have zero exp. in programming and have been told Python is a good starting point. If anyone knows of any web tutorials or books to get me started please reply. Also if you are nice enough to give some friendly advice that would be great too. DrYarbles DrYarbles wrote: > I have decided to learn a programming language and decided on Python. > I have zero exp. in programming and have been told Python is a good > starting point. If anyone knows of any web tutorials or books to get > me started please reply. Also i...

Web resources about - Python to Python communication - comp.lang.python


Communication - Wikipedia, the free encyclopedia
) is the activity of conveying information through the exchange of ideas, feelings, intentions, attitudes, expectations, perceptions or commands, ...

VoIP Business, VoIP Technology, VoIP Security - Fierce Enterprise Communications
Visit FierceVoIP for the latest updates in VoIP business, unified communications, VoIP technology, mobile VoIP, VoIP security and more VoIP news. ...

Mobile News Online - The UK's leading mobile communication industry news site
This month, thousands of students will be starting university for the first time. Some will need new phones. Mystery Caller is on the case to ...

Workers at the Communications Department are Australia's unluckiest public servants
They've lost a quarter of their colleagues, their popular boss and now they are being left behind on pay.

Workers at the Communications Department are Australia's unluckiest public servants
They've lost a quarter of their colleagues, their popular boss and now they are being left behind on pay.

How to Transcend Workplace Communication in the Emoji Era
... growing rapidly, with users in the hundreds of millions, both at work and play. The popularity of these messaging tools and the visual communication ...

ICC receives second war crimes communication from Palestinian human rights organizations
ICC receives second war crimes communication from Palestinian human rights organizations

Slack for iOS updated for improved team communication
We here at AppAdvice use Slack for everyday team communication . And according to Slacks second-anniversary blog post , so do at least 2 million ...

How communication tools are being used in the workplace
Interaction at work has been changed in recent years thanks to tools like Slack, but what do IT managers look for when sourcing communication ...

Just how much access does the NSA have to all unencrypted communications?
... attacks “would not have happened,” without encryption. So does that mean the NSA can listen to everything except encrypted chats and communications? ...

Resources last updated: 2/22/2016 12:07:01 AM