Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread MRAB
On 23/11/2013 22:29, Bhanu Karthik wrote:> On Saturday, 23 November 2013 14:23:08 UTC-8, Chris Angelico wrote: >> On Sun, Nov 24, 2013 at 9:15 AM, Bhanu Karthik >> wrote: >> > data = sock.recv(RECV_BUFFER) >> > username = str(sock.getpeername()) >> >

Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread Chris Angelico
On Sun, Nov 24, 2013 at 9:39 AM, Bhanu Karthik wrote: > indentation is correct when I trying to paste it here,it is showing like it > is unindented. That's because Google Groups mucks things up. Get a better client. ChrisA -- https://mail.python.org/mailman/listinfo/python-list

Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread Bhanu Karthik
On Saturday, 23 November 2013 14:37:09 UTC-8, Roy Smith wrote: > In article <8445e47e-7efe-4f37-9b40-db2896d58...@googlegroups.com>, > > Bhanu Karthik wrote: > > > > > data = sock.recv(RECV_BUFFER) > > > username = str(sock.getpeername()) > > >

Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread Chris Angelico
On Sun, Nov 24, 2013 at 9:33 AM, Bhanu Karthik wrote: > this is exact code.. > it is not even entering the if ... > I tried ( c= (data is '/quit')if c) > > when i print c ,its printing falseI dont understand what is > happening...please help.. Again, please get off Google Groups. Have a look

Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread Roy Smith
In article <8445e47e-7efe-4f37-9b40-db2896d58...@googlegroups.com>, Bhanu Karthik wrote: > data = sock.recv(RECV_BUFFER) > username = str(sock.getpeername()) > username = usernames[username] > if data == "/quit"

Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread Bhanu Karthik
On Saturday, 23 November 2013 14:23:08 UTC-8, Chris Angelico wrote: > On Sun, Nov 24, 2013 at 9:15 AM, Bhanu Karthik > > wrote: > > > data = sock.recv(RECV_BUFFER) > > > username = str(sock.getpeername()) > > > username = usernames[usern

Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread Chris Angelico
On Sun, Nov 24, 2013 at 9:29 AM, Bhanu Karthik wrote: > sorry its not command its data > > I miss wrote it here... Okay. Start by copying and pasting your actual code, and saying what you're doing to trigger it. If this is a stream socket (eg TCP), you have no way of knowing where one read wi

Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread Bhanu Karthik
On Saturday, 23 November 2013 14:23:08 UTC-8, Chris Angelico wrote: > On Sun, Nov 24, 2013 at 9:15 AM, Bhanu Karthik > > wrote: > > > data = sock.recv(RECV_BUFFER) > > > username = str(sock.getpeername()) > > > username = usernames[usern

Re: stuck at this from so much time,need help....please ..

2013-11-23 Thread Chris Angelico
On Sun, Nov 24, 2013 at 9:15 AM, Bhanu Karthik wrote: > data = sock.recv(RECV_BUFFER) > username = str(sock.getpeername()) > username = usernames[username] > if command == "/quit": >

stuck at this from so much time,need help....please ..

2013-11-23 Thread Bhanu Karthik
data = sock.recv(RECV_BUFFER) username = str(sock.getpeername()) username = usernames[username] if command == "/quit": print data sock.send("bye"