A tool, based on socket, to make sending big files(like images) easier/simpler.
Project description
easySocket
"easySocket" is a module for Python that's based on the "socket" module and aims to make tasks like sending long texts or files easier/simpler.
To install it, just put the .py file into your Python module directory (/path/to/your/pythonfolder/Lib/site-packages) or type "pip install easySocket" into your terminal window
Right now it can do the following:
-Host a tcp connection with one function: host_tcp(my_ip, port)
(This also returns the client as a socket.socket variable)
-Connect to a tcp conenction with one function: connect_tcp(ip, port)
(This also returns the server as a socket.socket variable)
-Send a file over a tcp connection independent of size: send_file(location, recipient)
-Send a file over a tcp connection independent of size: send_text(text, recipient)
-Aswell as receiving the data send by those two functions: rcv_data(sender)
I wrote this module, because I wanted to send an image with the socket module and found it annoying to always spend multiple lines of code to be able to send an image that was bigger than the maximum amount of bytes sendable with one socket.send command.
If you have any functions you think should be a part of this module just do a pull request or write your request under the Issues-Tab.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for easySocket-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5c12463a9260769b28c81bbaa7716333dcf965f6eeaa061808e1b6932523354f |
|
MD5 | 3c31cad94d92b108383dc8d3aad1e292 |
|
BLAKE2b-256 | a0a621ab5d6b6791553f25e87544bbdfb9b5460e6968eb844d8f3cd636610fd5 |