Python Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPython Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old December 10th, 2001, 01:15 PM
NeuroMorphus NeuroMorphus is offline
SourceSkipper
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2001
Location: Atlanta, GA.
Posts: 1 NeuroMorphus User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via AIM to NeuroMorphus
Question Client/Server Question

<b>Statement</b>

I'm creating a client/server chat program on my Linux system. It's a group chat like ICQ, so all messages go through the server and then to then broadcast to online users. Note: for the time being, this program will operate in a <b>terminal/console</b>, so no gui.

<b>Problem</b>

The client program continuously asks for 'raw_input' from the user,and then sends the msg to the server to be broadcasted. However, I can't output messages to the terminal/console, if the client program is waiting for input. What happens is that after the client types a message. All previous output(of other users) are then flush to that client's screen. In other words, how do i get client input and display current messages to the client's
screen without having to wait for the clients input. NOte: this is a terminal.

Telnet does it some kinda way(it works perfect), but i'm trying to get my client to work the same way.
Comments on this post
JimmyGosling agrees!

Reply With Quote
  #2  
Old December 11th, 2001, 03:16 AM
Taradino Taradino is offline
Python Prophet
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2001
Location: Amersfoort, The Netherlands
Posts: 45 Taradino User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
I'm not really sure, I've never had to use it this way, but I guess you could use the curses module: Documentation and an HOWTO.
__________________
Some people, when confronted with a problem, think “I know, I'll use regular expressions.” Now they have two problems. - Jamie Zawinski, in comp.lang.emacs

Reply With Quote
  #3  
Old December 11th, 2001, 04:53 PM
NeuroMorphus NeuroMorphus is offline
SourceSkipper
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2001
Location: Atlanta, GA.
Posts: 1 NeuroMorphus User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via AIM to NeuroMorphus
Smile I've got it now

I'll just make use of python select() method...

Reply With Quote
  #4  
Old December 12th, 2001, 03:08 AM
Taradino Taradino is offline
Python Prophet
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2001
Location: Amersfoort, The Netherlands
Posts: 45 Taradino User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Okay, cool.

/me learned something new

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPython Programming > Client/Server Question


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway