Re: Socket programming

2016-09-26 Thread haaruunibrow
use > client: > server_address='192.168.2.2' server: > server_name='127.0.0.1' -- https://mail.python.org/mailman/listinfo/python-list

Re: Socket programming

2015-01-04 Thread Jorgen Grahn
On Sat, 2015-01-03, Dan Stromberg wrote: > On Sat, Jan 3, 2015 at 3:43 AM, pramod gowda wrote: ... > data=client_socket.recv(1024) > print(data) > client_socket.close() > > > But note that if you send 10 bytes into a socket, it could be received > as two chunks of 5, or other strangeness. So you

Re: Socket programming

2015-01-03 Thread Dan Stromberg
On Sat, Jan 3, 2015 at 3:43 AM, pramod gowda wrote: > Hi i am learning socket programming, This "works" on Linux Mint 17.1. Server: #!/usr/local/cpython-3.4/bin/python import socket server_socket = socket.socket() #server_name = '192.168.2.2' server_socket.setso

Re: Socket programming

2015-01-03 Thread pramod gowda
On Saturday, January 3, 2015 9:27:20 PM UTC+5:30, Steven D'Aprano wrote: > pramod gowda wrote: > > > HI, i m doing n personal laptop. > > so i think i ve rights to open a listening socket,could u pls tell me hw > > can i check it? > > Is your keyboard broken? There are a lot of missing characters

Re: Socket programming

2015-01-03 Thread Steven D'Aprano
pramod gowda wrote: > HI, i m doing n personal laptop. > so i think i ve rights to open a listening socket,could u pls tell me hw > can i check it? Is your keyboard broken? There are a lot of missing characters in your sentences. You're going to have a lot of trouble programming with a broken key

Re: Socket programming

2015-01-03 Thread pramod gowda
On Saturday, January 3, 2015 8:39:26 PM UTC+5:30, mm0fmf wrote: > On 03/01/2015 11:43, pramod gowda wrote: > > server_socket=socket.socket() > > server_name='192.168.2.2' > > server_port= 80 > > server_socket.bind((server_name,server_port)) > > server_socket.listen(1) > > I don't do much Python on

Re: Socket programming

2015-01-03 Thread mm0fmf
On 03/01/2015 11:43, pramod gowda wrote: server_socket=socket.socket() server_name='192.168.2.2' server_port= 80 server_socket.bind((server_name,server_port)) server_socket.listen(1) I don't do much Python on Windows but do you have the necessary access rights to open a listening socket on por

Re: Socket programming

2015-01-03 Thread pramod gowda
On Saturday, January 3, 2015 6:08:28 PM UTC+5:30, Chris Angelico wrote: > On Sat, Jan 3, 2015 at 11:25 PM, pramod gowda wrote: > > I am using python 3.4.2 > > I don get any exceptions, > > but wn i run the code,i don see any connections, IP address is given as my > > system IP. > > What does the

Re: Socket programming

2015-01-03 Thread Chris Angelico
On Sat, Jan 3, 2015 at 11:25 PM, pramod gowda wrote: > I am using python 3.4.2 > I don get any exceptions, > but wn i run the code,i don see any connections, IP address is given as my > system IP. What does the client say? ChrisA -- https://mail.python.org/mailman/listinfo/python-list

Re: Socket programming

2015-01-03 Thread pramod gowda
On Saturday, January 3, 2015 5:26:27 PM UTC+5:30, Chris Angelico wrote: > On Sat, Jan 3, 2015 at 10:43 PM, pramod gowda wrote: > > I am not getting the output, i am using windows 7 OS.. > > please check and give me the solution. > > Windows 7 - that's part of the story. What version of Python ar

Re: Socket programming

2015-01-03 Thread Chris Angelico
On Sat, Jan 3, 2015 at 10:43 PM, pramod gowda wrote: > I am not getting the output, i am using windows 7 OS.. > please check and give me the solution. Windows 7 - that's part of the story. What version of Python are you using? Is 192.168.2.2 the correct IP address? What happens when you run thes

Socket programming

2015-01-03 Thread pramod gowda
Hi i am learning socket programming, client code: import socket client_socket=socket.socket() server_address='192.168.2.2' server_port= 80 print("hello") client_socket.connect((server_address,server_port)) print("hello") data=client_socket.recv(1024) print(data)

Re: socket programming

2013-05-06 Thread Arnaud Delobelle
On 6 May 2013 17:05, Chris Angelico wrote: > I've never used Twisted, so I can't say how good it is. All I know is > that what I learned about socket programming in C on OS/2 is still > valid on Windows and on Linux, and in every language I've ever used > (bar JavaScr

Re: socket programming

2013-05-06 Thread Chris Angelico
ed, so I can't say how good it is. All I know is that what I learned about socket programming in C on OS/2 is still valid on Windows and on Linux, and in every language I've ever used (bar JavaScript and ActionScript, which are deliberately sandboxed and thus don't have direct sock

Re: socket programming

2013-05-06 Thread Pedro
perhaps '\n'), fixed length buffers, or to always close the socket after every single message (but that is hugely inefficient if you need to send multiple messages). > s.close # Close the socket when done > Oh, you forgot the parentheses here: s.close() Bottom line: Socket prog

Re: socket programming

2013-05-04 Thread Chris Angelico
On Sat, May 4, 2013 at 7:37 PM, Irmen de Jong wrote: > Bottom line: > Socket programming on this level is hugely complicated. It doesn't seem too > bad if you > start of with these simple example programs, but that's false hope. If at all > possible, > avoid direct s

Re: socket programming

2013-05-04 Thread Irmen de Jong
s '\n'), fixed length buffers, or to always close the socket after every single message (but that is hugely inefficient if you need to send multiple messages). > s.close # Close the socket when done > Oh, you forgot the parentheses here: s.close() Bottom l

Re: socket programming

2013-05-03 Thread Pedro
On Friday, May 3, 2013 11:56:01 PM UTC-4, Chris Angelico wrote: > On Sat, May 4, 2013 at 1:37 PM, Pedro wrote: > > > On Friday, May 3, 2013 10:23:38 PM UTC-4, Chris Angelico wrote: > > >> The accept() call should block. It's not going to spin or anything. If > > >> > > >> you need to monitor m

Re: socket programming

2013-05-03 Thread Chris Angelico
On Sat, May 4, 2013 at 1:37 PM, Pedro wrote: > On Friday, May 3, 2013 10:23:38 PM UTC-4, Chris Angelico wrote: >> The accept() call should block. It's not going to spin or anything. If >> >> you need to monitor multiple sockets, have a look at select(). > > Thanks Chris, can you elaborate on the a

Re: socket programming

2013-05-03 Thread Pedro
On Friday, May 3, 2013 10:23:38 PM UTC-4, Chris Angelico wrote: > On Sat, May 4, 2013 at 12:13 PM, Pedro wrote: > > > First - this code constantly loops around an open socket. Is there a way to > > use something like an interrupt so I don't have to loop constantly to > > monitor the socket? >

Re: socket programming

2013-05-03 Thread Chris Angelico
On Sat, May 4, 2013 at 12:13 PM, Pedro wrote: > First - this code constantly loops around an open socket. Is there a way to > use something like an interrupt so I don't have to loop constantly to monitor > the socket? The accept() call should block. It's not going to spin or anything. If you ne

socket programming

2013-05-03 Thread Pedro
I'm writing a simple app that uses socket programming, I'm using the following from tutorialspoint as a framework but I'm having a couple of issues implementing it. First - this code constantly loops around an open socket. Is there a way to use something like an interrupt so

Re: Network and socket programming in python

2010-09-05 Thread simpu
On Sep 5, 3:29 pm, geremy condra wrote: > On Sat, Sep 4, 2010 at 9:29 PM, shivram wrote: > > i want to learn network and socket programming but i would like to do > > this in python.Reason behind this is that python is very simple and > > the only language i know . >

Re: Network and socket programming in python

2010-09-05 Thread geremy condra
On Sat, Sep 4, 2010 at 9:29 PM, shivram wrote: > i want to learn network and socket programming but i would like to do > this in python.Reason behind this is that python is very simple and > the only language i know . > anybody can suggest me which book should i pick. > the b

Re: Network and socket programming in python

2010-09-05 Thread mblume
Am Sat, 04 Sep 2010 21:29:49 -0700 schrieb shivram: > > i want to learn network and socket programming but i would like to do > this in python.Reason behind this is that python is very simple and the > only language i know . > anybody can suggest me which book should i pick. the b

Network and socket programming in python

2010-09-04 Thread shivram
i want to learn network and socket programming but i would like to do this in python.Reason behind this is that python is very simple and the only language i know . anybody can suggest me which book should i pick. the book should have following specification-- 1)not tedious to follow 2)lots of

Re: socket programming

2009-12-30 Thread Mark Tolonen
"Zubin Mithra" wrote in message news:8e7c74320912300315r625f4c89kb8002e4b8c384...@mail.gmail.com... The code snippet i have pasted at, http://paste.pocoo.org/show/160555/ produces a traceback which also has been pasted at the above link. The snippet attempts at socket programming

socket programming

2009-12-30 Thread Zubin Mithra
The code snippet i have pasted at, http://paste.pocoo.org/show/160555/ produces a traceback which also has been pasted at the above link. The snippet attempts at socket programming using OOPs concepts. Please help. Thankx in advance Zubin Mithra -- http://mail.python.org/mailman/listinfo

Socket programming with NetCom serial-to-ethernet module

2009-11-09 Thread Ryan Swindle
Hi, This is my first Python-list post; I hope it's going to the right place. Here's my problem: I've read many tutorials on socket programming, but I can't seem to piece them together for my particular case. I have 3 serial ports, each of which individually connects to a

Socket Programming through Proxy

2009-09-22 Thread Arnab Chakraborty
I have written client-server programs in python. They seem to be working fine in the same computer, even on two different computers when directly connected through a Lan wire, but it wouldn't work in my college LAN. I think it is due to the proxy server through which all the computers in our LAN ne

Re: problem on socket programming

2009-07-31 Thread Gabriel Genellina
En Fri, 31 Jul 2009 10:43:49 -0300, MalC0de escribió: none of you can't interpret it ? do you have errors like me !? Have you tried Diez B. Roggisch suggestion? : Can you ping and telnet to the port on the desired server? Firewalls can be an issue here. The official doc page for the soc

Re: problem on socket programming

2009-07-31 Thread MalC0de
none of you can't interpret it ? do you have errors like me !? -- http://mail.python.org/mailman/listinfo/python-list

Re: problem on socket programming

2009-07-31 Thread Processor-Dev1l
On Jul 31, 2:37 pm, MalC0de wrote: > no, I disabled my firewall, no problem with even enabled firewall ... > no one can help !? Connection refused... connection was refused by the listening socket, it could also be due to the settings of your service, if it accepts only from localhost to localhos

Re: problem on socket programming

2009-07-31 Thread MRAB
MalC0de wrote: no, I disabled my firewall, no problem with even enabled firewall ... no one can help !? I hope you disconnected your computer from the internet before disabling the firewall... -- http://mail.python.org/mailman/listinfo/python-list

Re: problem on socket programming

2009-07-31 Thread MalC0de
no, I disabled my firewall, no problem with even enabled firewall ... no one can help !? -- http://mail.python.org/mailman/listinfo/python-list

Re: problem on socket programming

2009-07-31 Thread Diez B. Roggisch
MalC0de schrieb: you want to say shall i disable the firewall, there's no specific firewall or IPS/IDS system out there, this is just windows xp firewall Which is a firewall, don't you agree? So it could well be the reason for the problems you see. Diez -- http://mail.python.org/mailman/lis

Re: problem on socket programming

2009-07-31 Thread MalC0de
you want to say shall i disable the firewall, there's no specific firewall or IPS/IDS system out there, this is just windows xp firewall -- http://mail.python.org/mailman/listinfo/python-list

Re: problem on socket programming

2009-07-31 Thread Diez B. Roggisch
MalC0de schrieb: On Jul 31, 12:07 pm, Chris Rebert wrote: On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote: now I've been encountered to some errors with this snippet : And these errors are? Provide error messages and full tracebacks. Cheers, Chris --http://blog.rebertia.com these are errors

Re: problem on socket programming

2009-07-31 Thread Diez B. Roggisch
MalC0de schrieb: On Jul 31, 12:07 pm, Chris Rebert wrote: On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote: now I've been encountered to some errors with this snippet : And these errors are? Provide error messages and full tracebacks. Cheers, Chris --http://blog.rebertia.com these are errors

Re: problem on socket programming

2009-07-31 Thread Piet van Oostrum
> MalC0de (M) wrote: >M> On Jul 31, 12:07 pm, Chris Rebert wrote: >>> On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote: >>> > now I've been encountered to some errors with this snippet : >>> >>> And these errors are? Provide error messages and full tracebacks. >>> >>> Cheers, >>> Chris >>> -

Re: problem on socket programming

2009-07-31 Thread MalC0de
On Jul 31, 12:07 pm, Chris Rebert wrote: > On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote: > > now I've been encountered to some errors with this snippet : > > And these errors are? Provide error messages and full tracebacks. > > Cheers, > Chris > --http://blog.rebertia.com these are errors : Tr

Re: problem on socket programming

2009-07-31 Thread Chris Rebert
On Fri, Jul 31, 2009 at 1:02 AM, MalC0de wrote: > now I've been encountered to some errors with this snippet : And these errors are? Provide error messages and full tracebacks. Cheers, Chris -- http://blog.rebertia.com -- http://mail.python.org/mailman/listinfo/python-list

Re: problem on socket programming

2009-07-31 Thread MalC0de
now I've been encountered to some errors with this snippet : import sys from socket import * serverHost = 'localhost' serverPort = 50007 message = ['Hello network world'] if len(sys.argv) > 1: serverHost = sys.argv[1] if len(sys.argv) > 2: message = sys.argv[2:] sockobj = socket(AF

Re: problem on socket programming

2009-07-31 Thread MalC0de
problem with this code solved in win32, but I didn't test it after solved problem on gnu/linux . -- http://mail.python.org/mailman/listinfo/python-list

Re: problem on socket programming

2009-07-31 Thread Xavier Ho
Whoops, posted to the wrong address yet again. I deserve some punishment. On Fri, Jul 31, 2009 at 5:33 PM, Xavier Ho wrote: > On Fri, Jul 31, 2009 at 5:25 PM, MalC0de wrote: > >> >> while true : >> >> where's the problem, > > > There. =] > (Btw, it's True, not true.) -- http://mail.python

problem on socket programming

2009-07-31 Thread MalC0de
hello there, I'm using Learning Python 3rd edition as my core reference, the book is great. here's some snippet for demonstrating echo-server program, but I can't interpret it in both windows / Gnu linux ... #!/usr/bin/env python from socket import * myHost = '' myPort = 50007 sockobj = socket(AF_

Re: Socket Programming and Data transer 'advice'

2008-11-17 Thread Chris Rebert
On Mon, Nov 17, 2008 at 10:42 AM, Abah Joseph <[EMAIL PROTECTED]> wrote: > I am planning to develop School Database Management System that will run on > Windows, Linux and Mac. The application will be Server/Client and GUI based. Have you considered basing this off existing software for schools, l

Socket Programming and Data transer 'advice'

2008-11-17 Thread Abah Joseph
I am planning to develop School Database Management System that will run on Windows, Linux and Mac. The application will be Server/Client and GUI based. Modules I intende to use are: Python socket module, wxPython for GUI, Open GL for image processing , email and so on. This is my first real pyt

Re: socket programming (client-server) error

2008-10-23 Thread Python
On 23 okt 2008, at 05:49, ryan wrote: On Oct 22, 6:18 pm, Python <[EMAIL PROTECTED]> wrote: On 22 okt 2008, at 13:50, ryan fox wrote: i have implemented a small client server model to do file transfer over a LAN network. It work with some machines on the network and on others it doesnt.

Re: socket programming (client-server)

2008-10-22 Thread Larry Bates
ryan wrote: i have implemented a small client server model to do file transfer over a LAN network. It work with some machines on the network and on others it doesnt. when i run the server.py file in some machine then it pops up a windows security alert. The message is as follows: Do you

Re: socket programming (client-server) error

2008-10-22 Thread James Mills
On Thu, Oct 23, 2008 at 1:49 PM, ryan <[EMAIL PROTECTED]> wrote: > any ideas? As mentioned before, try: * Turning _off_ _all_ _firewalls_. cheers James -- -- -- "Problems are solved by method" -- http://mail.python.org/mailman/listinfo/python-list

Re: socket programming (client-server) error

2008-10-22 Thread ryan
On Oct 22, 6:18 pm, Python <[EMAIL PROTECTED]> wrote: > On 22 okt 2008, at 13:50, ryan fox wrote: > > > > > i have implemented a small client server model to do file transfer > > over a LAN network. > > > It work with some machines on the network and on others it doesnt. > > when i run the server.p

Re: socket programming (client-server) error

2008-10-22 Thread Python
On 22 okt 2008, at 13:50, ryan fox wrote: i have implemented a small client server model to do file transfer over a LAN network. It work with some machines on the network and on others it doesnt. when i run the server.py file in some machine then it pops up a windows security alert. The messa

Re: socket programming (client-server) error

2008-10-22 Thread James Mills
On Wed, Oct 22, 2008 at 9:50 PM, ryan fox <[EMAIL PROTECTED]> wrote: > I guess its a firewall problem... How do i go abt it? > any help? See as it's most likely a firewall issue and a firewall that I'm not familiar with, I can't help here :/ Sorry. cheers James -- -- -- "Problems are solved

socket programming (client-server) error

2008-10-22 Thread ryan fox
i have implemented a small client server model to do file transfer over a LAN network. It work with some machines on the network and on others it doesnt. when i run the server.py file in some machine then it pops up a windows security alert. The message is as follows: Do you want to keep bl

socket programming (client-server)

2008-10-22 Thread ryan
i have implemented a small client server model to do file transfer over a LAN network. It work with some machines on the network and on others it doesnt. when i run the server.py file in some machine then it pops up a windows security alert. The message is as follows: Do you want to keep b

python socket programming

2008-06-19 Thread srinivasan srinivas
HI, I want to know the different kind of exceptions may occur in client-server  socket communication and the way to handle those scenarios. 1. What does the server do when a socket error occurs at any point: accepting a connection, sending data to a client, receiving data from a client, waiting f

Re: One more socket programming question

2008-06-18 Thread John Salerno
"Tim Roberts" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > John Salerno <[EMAIL PROTECTED]> wrote: >> >>I'm now experimenting with the SocketServer class. Originally I >>subclassed the StreamRequestHandler to make my own custom handler, but a >>result of this seems to be that the

Re: One more socket programming question

2008-06-18 Thread Tim Roberts
John Salerno <[EMAIL PROTECTED]> wrote: > >I'm now experimenting with the SocketServer class. Originally I >subclassed the StreamRequestHandler to make my own custom handler, but a >result of this seems to be that the client socket closes after it has >been used, instead of staying open. Right.

One more socket programming question

2008-06-17 Thread John Salerno
I'm now experimenting with the SocketServer class. Originally I subclassed the StreamRequestHandler to make my own custom handler, but a result of this seems to be that the client socket closes after it has been used, instead of staying open. Just as a test, I decided to use BaseRequestHandler

Re: Socket Programming

2008-06-14 Thread Jeff McNeil
On Jun 14, 5:38 pm, srinivasan srinivas <[EMAIL PROTECTED]> wrote: > Hi, > Is there any way(method) to find whether the socket got closed or not?? > Thanks, > Srini > >       Best Jokes, Best Friends, Best Food and more. Go > tohttp://in.promos.yahoo.com/groups/bestofyahoo/ That's slightly diffi

Socket Programming

2008-06-14 Thread srinivasan srinivas
Hi, Is there any way(method) to find whether the socket got closed or not?? Thanks, Srini Best Jokes, Best Friends, Best Food and more. Go to http://in.promos.yahoo.com/groups/bestofyahoo/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Python Socket programming

2008-06-13 Thread William McBrine
On Fri, 13 Jun 2008 21:59:06 +0530, srinivasan srinivas wrote: > I am going to do some socket related programming in Python. Before that, > I wish to know the Gotchas of Python Scoket Programming. The only gotcha I see is that you won't want to go back to doing it in C. -- 09 F9 11 02 9D 74 E3

Re: Python Socket programming

2008-06-13 Thread Dan Stromberg
On Fri, 13 Jun 2008 21:59:06 +0530, srinivasan srinivas wrote: > Hi, > I am going to do some socket related programming in Python. Before that, > I wish to know the Gotchas of Python Scoket Programming. Can anyone send > me any link that satisfies my needs?? Thanks, > Srini > > > Explore y

Re: Python Socket programming

2008-06-13 Thread Vishang Shah
there is this good link for explanation on how sockets work, http://www.tutorialgrub.com/tutorials/Python/Development/Socket-Programming-HOWTO_325.html -- http://mail.python.org/mailman/listinfo/python-list

Re: Python Socket programming

2008-06-13 Thread Cédric Lucantis
Hi, Le Friday 13 June 2008 18:29:06 srinivasan srinivas, vous avez écrit : > Hi, > I am going to do some socket related programming in Python. Before that, I > wish to know the Gotchas of Python Scoket Programming. Can anyone send me > any link that satisfies my needs?? Yes, the friendly manual :

Python Socket programming

2008-06-13 Thread srinivasan srinivas
Hi, I am going to do some socket related programming in Python. Before that, I wish to know the Gotchas of Python Scoket Programming. Can anyone send me any link that satisfies my needs?? Thanks, Srini Explore your hobbies and interests. Go to http://in.promos.yahoo.com/groups/ -- http://

Re: socket programming related.

2007-07-11 Thread Simon Percivall
On Jul 12, 2:35 am, [EMAIL PROTECTED] wrote: > On Jul 11, 7:32 pm, [EMAIL PROTECTED] wrote: > > > I have just started working in network programming using python. > > written code for socket connection between client and server. Client > > sent data to server for server processing (also server echo

socket programming related.

2007-07-11 Thread hari . siri74
I have just started working in network programming using python. written code for socket connection between client and server. Client sent data to server for server processing (also server echoing back rcvd data to client). When there is ("if no data": break ) no data from client then the while loo

Re: socket programming related.

2007-07-11 Thread hari . siri74
On Jul 11, 7:32 pm, [EMAIL PROTECTED] wrote: > I have just started working in network programming using python. > written code for socket connection between client and server. Client > sent data to server for server processing (also server echoing back > rcvd data to client). When there is ("if no

Re: socket programming question

2006-06-20 Thread Grant Edwards
On 2006-06-20, Kiran <[EMAIL PROTECTED]> wrote: > is it possible to make python do some other processing while > it is waiting for a socket to timeout? Yes. You can either use threads or select. Or you can use one of the async server frameworks like twisted. -- Grant Edwards

Re: socket programming question

2006-06-20 Thread Irmen de Jong
Kiran wrote: > Hello All, > My question is, is it possible to make python do some other > processing while it is waiting for a socket to timeout? sure, you have to use threads and/or use asynchronous socket programming. Google is your friend. --Irmen -- http://mail.python.or

socket programming question

2006-06-20 Thread Kiran
Hello All, My question is, is it possible to make python do some other processing while it is waiting for a socket to timeout? thanks a lot! Kiran -- http://mail.python.org/mailman/listinfo/python-list

Re: Socket Programming - Question

2006-02-10 Thread Grant Edwards
On 2006-02-11, D <[EMAIL PROTECTED]> wrote: > I've used os.popen() before, but if I execute it on a remote > system how could I get the output back to the requesting > machine? Write it to the socket? -- Grant Edwards grante Yow! Where does it go when

Re: Socket Programming - Question

2006-02-10 Thread Paul Rubin
"[EMAIL PROTECTED]" <[EMAIL PROTECTED]> writes: > I am relatively new to Python, and wanted to see if this is even > possible, and if so how to go about implementing it. What I'm looking > to do is create a client/server application that does the following: > > 1) System2 listens on port > 1023

Re: Socket Programming - Question

2006-02-10 Thread D
I've used os.popen() before, but if I execute it on a remote system how could I get the output back to the requesting machine? -- http://mail.python.org/mailman/listinfo/python-list

Re: Socket Programming - Question

2006-02-10 Thread D
Thanks! Now, I'm a bit confused as to exactly how it works - will it display the output of what it executes on the target system? I would like to create a window in Tktinker to where a user can select options (such as run scan on remote system) - it would then run the command-line based scan and

Re: Socket Programming - Question

2006-02-10 Thread Grant Edwards
On 2006-02-11, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > I am relatively new to Python, and wanted to see if this is > even possible, and if so how to go about implementing it. > What I'm looking to do is create a client/server application > that does the following: > > 1) System2 listens on

Re: Socket Programming - Question

2006-02-10 Thread [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote: > An example of what I am looking to use this for is for remote virus > scanning. So System2 listens, System1 connects and sends it the Just found this through OSNews: http://rpyc.sourceforge.net/ It actually seems to be a perfect fit for your job. Lorenzo -- http://

Socket Programming - Question

2006-02-10 Thread [EMAIL PROTECTED]
I am relatively new to Python, and wanted to see if this is even possible, and if so how to go about implementing it. What I'm looking to do is create a client/server application that does the following: 1) System2 listens on port > 1023 2) System1 connects to System2 and sends traffic to it -

Re: Socket Programming HOWTO example

2006-01-17 Thread Bryan Olson
I mis-phrased: > The code passes > 'self' to __init__, but not to any of the others methods. Of course I meant that the formal parameter for self is missing. > > class mysocket: > >> '''classe solamente dimostrativa >> - codificata per chiarezza, non per efficenza''' >>

Re: Socket Programming HOWTO example

2006-01-17 Thread Bryan Olson
Marco Meoni wrote: > Hi. I read the Gordon McMillan's "Socket Programming Howto". > I tried to use the example in this howto but this doesn't work. You are right, that obviously won't work. The code passes 'self' to __init__, but not to any of the others

Hi, about socket programming and threading

2006-01-17 Thread Kr z
Hi All!I wonder if anyone knows the simple code structure for a multithreaded web server handling multiple clients at the same time?Thanx!Regards.KrzGet an advanced look at the new version of MSN Messenger. -- http://mail.python.org/mailman/listinfo/python-list

Re: Socket Programming HOWTO example

2006-01-17 Thread Manlio Perillo
Steve Holden ha scritto: > [...] > I can see you have changed the example a little (because I know that > Gordon's original didn't have comments in Italian). The example cames from italian translation of the howto: http://python.it/doc/howto/Socket/sockets-it/sockets-it.html Regards Manlio P

Re: Socket Programming HOWTO example

2006-01-16 Thread Steve Holden
Marco Meoni wrote: > Hi. I read the Gordon McMillan's "Socket Programming Howto". > I tried to use the example in this howto but this doesn't work. > The code is class mysocket: > '''classe solamente dimostrativa > - codificata

Socket Programming HOWTO example

2006-01-16 Thread Marco Meoni
Hi. I read the Gordon McMillan's "Socket Programming Howto". I tried to use the example in this howto but this doesn't work. The code is class mysocket: '''classe solamente dimostrativa - codificata per chiarezza, non per efficenza'

Re: Socket programming design problem

2005-12-22 Thread Dan Sommers
On Thu, 22 Dec 2005 22:12:09 +, David <[EMAIL PROTECTED]> wrote: > a) Big problem, I can't see how to receive from more than one socket > at once. I need to do this so that data from the TCP connection can > be sent out on the UDP one and vice versa. Do I need a thread for > each, or is ther

Re: Socket programming design problem

2005-12-22 Thread John J. Lee
David <[EMAIL PROTECTED]> writes: [...] > a) Big problem, I can't see how to receive from more than one socket at > once. I need to do this so that data from the TCP connection can be sent > out on the UDP one and vice versa. Do I need a thread for each, or is > there some other way I can listen

Socket programming design problem

2005-12-22 Thread David
After programming with Python for a few hours, I've come up with some code: http://p.shurl.net/3n. However, now I've realised there's a bit of a problem with the original design. I have a number of questions, if anybody could answer I'd be grateful. a) Big problem, I can't see how to receive fro

Re: tcp socket programming

2005-10-04 Thread Mohammed Smadi
On Tue, 4 Oct 2005, Irmen de Jong wrote: > Mohammed Smadi wrote: > > hi; > > If i have a tcp connection with a remote server, what is a good way to > > read all the data into a buffer before starting to process the data? > > I know that the data recieved will be 3 lines with CRLF between them.

Re: tcp socket programming

2005-10-04 Thread Irmen de Jong
Mohammed Smadi wrote: > hi; > If i have a tcp connection with a remote server, what is a good way to > read all the data into a buffer before starting to process the data? > I know that the data recieved will be 3 lines with CRLF between them. > However if I can sock.recv(1024) the output is not

tcp socket programming

2005-10-04 Thread Mohammed Smadi
hi; If i have a tcp connection with a remote server, what is a good way to read all the data into a buffer before starting to process the data? I know that the data recieved will be 3 lines with CRLF between them. However if I can sock.recv(1024) the output is not consistent all the time, somet

Re: socket programming

2005-07-21 Thread Helge Aksdal
* gry@ll.mit.edu [2005/07/20 15:26]: > What I have done in similar circumstances is put in a random sleep > between connections to fool the server's load manager. Something like: > > .import time > .min_pause,max_pause = (5.0, 10.0) #seconds > .while True: > . time.sleep(random.uniform(min_p

Re: socket programming

2005-07-20 Thread Helge Aksdal
* gry@ll.mit.edu [2005/07/20 15:26]: > What I have done in similar circumstances is put in a random sleep > between connections to fool the server's load manager. Something like: > > .import time > .min_pause,max_pause = (5.0, 10.0) #seconds > .while True: > . time.sleep(random.uniform(min_pa

Re: socket programming

2005-07-20 Thread gry
What I have done in similar circumstances is put in a random sleep between connections to fool the server's load manager. Something like: .import time .min_pause,max_pause = (5.0, 10.0) #seconds .while True: . time.sleep(random.uniform(min_pause, max_pause)) . do_connection_and_query_stuff()

Re: socket programming

2005-07-19 Thread Terry Reedy
"Helge Aksdal" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >* Terry Reedy <[EMAIL PROTECTED]> [2005/07/19 22:57]: > >> Ask your server administrator if you are bumping up against a hidden >> connection limit. Or if a query can ask about multiple accounts. > > how can i use a conn

Re: socket programming

2005-07-19 Thread John Hazen
* Helge Aksdal <[EMAIL PROTECTED]> [2005-07-19 11:23]: > if i then change to a console window, and telnet to this server it > sends me to another one. That's probably why my program dies, how > can i get my code to handle this? > > Trying xxx.xxx.xxx.xxx > telnet: connect to address xxx.xxx.xxx.xx

Re: socket programming

2005-07-19 Thread Grant Edwards
On 2005-07-19, Helge Aksdal <[EMAIL PROTECTED]> wrote: > if i then change to a console window, and telnet to this > server it sends me to another one. What do you mean "sends me to another one"? The telnet protocol doesn't have any sort of "redirect" capability. > That's probably why my program

Re: socket programming

2005-07-19 Thread Helge Aksdal
* Jaime Wyant <[EMAIL PROTECTED]> [2005/07/19 23:09]: > I don't think you can use a limit to your advantage. If you are > bumping against some limit and you can't query for multiple accounts > then there doesn't seem to be much you can really do. The problem would be solved, if i just could get

Re: socket programming

2005-07-19 Thread Jaime Wyant
On 7/19/05, Helge Aksdal <[EMAIL PROTECTED]> wrote: > * Terry Reedy <[EMAIL PROTECTED]> [2005/07/19 22:57]: > > > Ask your server administrator if you are bumping up against a hidden > > connection limit. Or if a query can ask about multiple accounts. > > how can i use a connection limit to my a

  1   2   >