|
by: Olivier Hoarau |
last post by:
Hello,
I have build a client/server application with the socket module. The
server mades UDP broadcasting and the client only reads UDP broadcast
messages. All work fine.
Now I want to use for the same thing the socketserver module, it's ok
for the client, but I don't succeed in making work the server :-((
Here is the client (which works)
|
by: Adil Hasan |
last post by:
Hello Fred,
I just ran across your question. I think that the following
code will work:
----- SERVER CODE ------
import SocketServer
import time
class GreetingHandler(SocketServer.BaseRequestHandler):
'''Class to handle sending a greeting to a client
'''
|
by: Brian |
last post by:
From one script, I'm spawnv'ing another that will launch mpg123 to play a
specified mp3. Problem is that After the second script has launched
mpg123, it'll turn into a zombie process. It doesn't happen when I launch
it from the command line, so there's something wrong with the way I'm
calling it (I believe).
mp3pid = os.spawnv(os.P_NOWAIT, "/oter/playfile.py", )
Shouldn't this launch the script without waiting for it to finish?
|
by: missiplicity |
last post by:
Hi,
I am newbie to Python language and am taking my baby steps. I am
using Python2.4 from ActiveState on W2K. I am trying to create a simple
SocketServer program. Just adding the following 2 lines of code in the
program result in the errors given below:
import SocketServer
print "SocketServer imported"
|
by: Paul Rubin |
last post by:
Let's say you have a SocketServer with the threading mix-in and you
run serve_forever on it. How can you shut it down, or rather, how can
it even shut itself down? Even if you use a handle_request loop
instead of serve_forever, it still seems difficult:
class myserver(ThreadingMixIn, TCPServer): pass
server = myserver(...)
server.shutdown = False
while not server.shutdown:
server.handle_request()
|
|
by: A. Tillman |
last post by:
We are having a really big problem with a zombie process/transaction
that is blocking other processes. When looking at Lock/ProcessID
under Current Activity I see a bunch of processes that are blocked by
process 94 and process 94 is blocked by process -2. I assume -2 is a
zombie that has an open transaction. I cannot find this process to
kill and it seems that this transaction is surviving database
restarts. I know which table is...
|
by: rbt |
last post by:
I've read more about sockets and now, I have a better understanding of
them. However, I still have a few SocketServer module questions:
When used with SocketServer how exactly does socket.setdefaulttimeout()
work? Does it timeout the initial connect request to the socket server
or does it timeout the session between the connecting client socket and
the client socket the server generated to handle the incoming request?
Also, since the...
|
by: Reid Priedhorsky |
last post by:
Dear all,
I have a TCP server written using SocketServer with ForkingMixIn.
Servicing connections is CPU-bound and can take several seconds.
I now need a way to safely tell the master process to update its state (by
groveling in a PostgreSQL database, potentially for several seconds). How
can I do this safely?
I thought of two ways:
|
by: Johny |
last post by:
To get a number of the http processes running on my Linux( Debia box)
I use
ps -ef | grep "ttpd" | wc -l
But If I want to use to get a number of the http processes from my
Python program I must use a popen command e.g.
popen2.popen3('ps -ef | grep "ttpd" | wc -l')
that is I must call an external command from Python.
But it creates a zombie.
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|