Python module which simplifies the task of writing network servers.
Questions tagged [socketserver]
385 questions
1
vote
1 answer
Setting up an Odoo 12 developer environment, Issues with Werkzeug version
I'm attempting to set up an Odoo 12 instance with a Python 3.7 virtualenv on Ubuntu version 18.04 using Pycharm. I keep getting issues related to Werkzeug as follows:
If I use the desired version of werkzueg written in the requirements.txt…

Rexox999
- 11
- 1
1
vote
1 answer
Spark's socket text stream is empty
I am following Spark's streaming guide. Instead of using nc -lk 9999, I have created my own simple Python server as follows. As can be seen from the code below, it will randomly generate the letters a through z.
import socketserver
import time
from…

Jane Wayne
- 8,205
- 17
- 75
- 120
1
vote
0 answers
How to integrate tcp-modbus with diffie hellman?
I have a simple modbus client-server code and also have a diffie-hellman client-server key exchange. My aim is to integrate the two so that when modbus client initiates request to modbus server, first step is do a key exchange and then encrypt the…

InfiniteMonkey13
- 33
- 4
1
vote
1 answer
TCP Socket What is the "flow of events" when two nodes talk
Relating to my previous question here, Previous Question, let me try to ask my question in laymen's terms (As I understand things in order to ask my question).
I am building a TCP client <--> server app.
Help me to understand what the correct…

Louis van Tonder
- 3,664
- 3
- 31
- 62
1
vote
1 answer
Script hangs when receiving data from socket
This is my Python script to receive data from client:
import time
import socket
HOST = ''
PORT = 8888
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
print('Socket created')
try:
s.bind((HOST, PORT))
except socket.error as socketError:
…

Sony
- 7,136
- 5
- 45
- 68
1
vote
0 answers
How to access to socket object from a different php file
I want to send something to my connected clients over another php script. But when I use the function "send", clientlist is null.
Can you help me about this please?
Socket.php:
$clientlist = array();
function run() {
global $clientlist;
…

Gubi123
- 11
- 1
1
vote
0 answers
share allocated memory buffer between c++ dynamic library and main C program
For work with C based socket server framework, we need to transfer data between socket server thread of C-based program and C++ based DLL.
Operation system MacOs.
Inside DLL everything works fine and we are able to manage OCR core and DB.
Inside of…

dharmabook.ru
- 107
- 1
- 6
1
vote
1 answer
Socket server in python refuses to connect
I am trying to create a simple web server with python using the following code.
However, When I run this code, I face this error:
ConnectionRefusedError: [WinError 10061] No connection could be made
because the target machine actively refused…

HoOman
- 455
- 1
- 7
- 15
1
vote
2 answers
Java socket client to server on different network.
My question:
How do I establish a connection from a client on one network to a server on another network in Java?
Background:
I created a simple client and server that communicate fine using localhost, or on two different computers using the same…

James
- 347
- 4
- 13
1
vote
2 answers
modify a function of a class from another class
In pymodbus library in server.sync, SocketServer.BaseRequestHandler is used, and defines as follow:
class ModbusBaseRequestHandler(socketserver.BaseRequestHandler):
""" Implements the modbus server protocol
This uses the…
user7656997
1
vote
1 answer
Multithreaded TCP socket
I'm trying to create a threaded TCP socket server that can handle multiple socket request at a time.
To test it, I launch several thread in the client side to see if my server can handle it. The first socket is printed successfully but I get a…

NicoAdrian
- 946
- 1
- 7
- 18
1
vote
0 answers
How to pause and resume 'socketserver'?
How do we pause and resume 'socketserver'???
I've been looking at socketserver documentation but I couldn't find the reference. https://docs.python.org/3.4/library/socketserver.html.
I initialize my socketserver
server =…

merry-go-round
- 4,533
- 10
- 54
- 102
1
vote
1 answer
Python socketserver different tasks
I have (what is likely) a very beginner-type question about sockets in Python 3 that I haven't been able to find an answer to so far:
Excluding options like threading or concurrency, what I'd like to know is, is it possible to send something like a…

NuclearFish
- 69
- 1
- 4
1
vote
1 answer
Python SocketServer send message from server
I use a TCP server in python, that implements this class:
class ThreadedTCPServer(SocketServer.ThreadingTCPServer):
pass
The normal use of it works perfect (initiating the server, handling requests and so on).
Now- I need to send a message to…

Shir
- 1,157
- 13
- 35
1
vote
1 answer
Python error TypeError: argument should be bytes, buffer or ASCII string, not 'NoneType'
I'm trying to create a tool to transfer binary files in python 3 and running into an odd issue on the server side. In the server code you will see I have one line commented out which prints the data received from the client to the screen.
With this…

user4573
- 21
- 1
- 1
- 4