Skip to main content

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

easySocket-0.0.3.tar.gz (2.4 kB view hashes)

Uploaded Source

Built Distribution

easySocket-0.0.3-py3-none-any.whl (3.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page