Path: csiph.com!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.005 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'debug': 0.05; 'means,': 0.07; 'twisted,': 0.07; 'python': 0.09; 'protocols.': 0.09; 'sockets': 0.09; 'aug': 0.13; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'personally,': 0.16; 'reason.': 0.16; 'sufficient,': 0.16; 'wrote:': 0.17; 'network.': 0.17; 'pointed': 0.17; 'tend': 0.17; 'received:209.85.214.174': 0.21; 'header:In-Reply-To:1': 0.25; 'plain': 0.27; 'executing': 0.27; 'message-id:@mail.gmail.com': 0.27; "doesn't": 0.28; 'run': 0.28; "d'aprano": 0.29; 'protocol.': 0.29; 'protocols': 0.29; 'remotely': 0.29; 'steven': 0.29; 'probably': 0.29; "i'm": 0.29; 'usually': 0.30; 'fri,': 0.30; 'code': 0.31; 'point': 0.31; 'running': 0.32; 'to:addr:python-list': 0.33; 'received:google.com': 0.34; 'awesome': 0.35; 'pm,': 0.35; 'received:209.85': 0.35; 'there': 0.35; 'but': 0.36; 'others.': 0.36; 'received:209': 0.37; 'subject:: ': 0.38; 'easier': 0.38; 'things': 0.38; 'instead': 0.39; 'to:addr:python.org': 0.39; 'received:209.85.214': 0.39; 'build': 0.39; 'header:Received:5': 0.40; 'your': 0.60; 'details': 0.63; 'internet': 0.71; 'subject:read': 0.84; 'text-based': 0.84; 'wheel': 0.84 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=M4HW8QmT92RAUEPARirXiDSAcX+rAgymvy5Qsjy9Q8I=; b=NYUsUcRvgRavv6t9gh3c+rWb4O+IEYJBVUyWBCrbIb4OKADTYyypzFOuP/OPb8cLcj ws9IBAYgjqvZf3ZjjsivneO6QUhwPVogUUTnzVit/QU8Va0KEHjBdZxGadjeDx79V5Ob 0jDTgMjYf/t9IVP3AS3ojJhkF8eVPNu9E7L9mWfg1su4oyoNLVUa2nntJqp2LPkO7rxi nWtDG1akfkaQKp3eAW3GXlrhx1H/y6e0+9qRaUrLrkodxxMFNQkGFlq6hhfiOp16at6V zI8Q6bkARQiZ2/1btNGMuJ0V/SYFkeTQ77nYQKPetknW1LlLNl6dRJiTfO0u6hha9XaJ OtvA== MIME-Version: 1.0 In-Reply-To: <502dac1e$0$29978$c3e8da3$5496439d@news.astraweb.com> References: <502dac1e$0$29978$c3e8da3$5496439d@news.astraweb.com> Date: Fri, 17 Aug 2012 17:25:31 +1000 Subject: Re: remote read eval print loop From: Chris Angelico To: python-list@python.org Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 22 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1345188334 news.xs4all.nl 6947 [2001:888:2000:d::a6]:43224 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:27225 On Fri, Aug 17, 2012 at 12:27 PM, Steven D'Aprano wrote: > There is already awesome protocols for running Python code remotely over > a network. Please do not re-invent the wheel without good reason. > > See pyro, twisted, rpyc, rpclib, jpc, and probably many others. But they're all tools for building protocols. I like to make line-based protocols that don't need middle-layers, you might like to use RPC, doesn't matter; either way, neither of us is sending untrusted code across the internet and executing it. By all means, use pyro instead of plain sockets to build your protocol; you still don't need a read/eval/print loop to run across a network. Personally, I'm of the opinion that simple text-based protocols are usually sufficient, and much easier to debug - heavier things like RPC tend to be overkill. But as Alister pointed out, my main point was not about the details of how you design your protocol. ChrisA