Skip to main content

Simple IPC server/client

Project description

PyPI PyPI - Python Version PyPI - Downloads PyPI - License Documentation Status Buy Me a Coffee

ipcs

A library for Python for IPC.
(Although it is written as IPC, it can also be used for communication with an external server.)

Installation

$ pip install ipcs

Examples

Run ipcs-server and run following code.

Client A

# Client A

from ipcs import Client, Request

client = Client("a")

@client.route()
async def hello(request: Request, word: str):
    print("Hello, %s!" % word)

client.run("ws://localhost/", port=8080)

Client B

# Client B

from ipcs import Client

client = Client("b")

@client.listen()
async def on_ready():
    # Run client a's hello str to say greetings to world.
    await client.request("a", "hello", "World")
    # or `await client.connections.a.request("hello", "World")`

client.run("ws://localhost/", port=8080)

License

The license is MIT and details can be found here.

Documentation

Documentation is avaliable here.

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

ipcs-0.2.0.tar.gz (14.3 kB view details)

Uploaded Source

Built Distribution

ipcs-0.2.0-py3-none-any.whl (15.5 kB view details)

Uploaded Python 3

File details

Details for the file ipcs-0.2.0.tar.gz.

File metadata

  • Download URL: ipcs-0.2.0.tar.gz
  • Upload date:
  • Size: 14.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.11

File hashes

Hashes for ipcs-0.2.0.tar.gz
Algorithm Hash digest
SHA256 c21d6f53ef6105ee44b77af6d884546e75baa13bc30751d7a1cab2b58f60ee10
MD5 234befe9d622f0725d429c150ca99982
BLAKE2b-256 88728f5ce888c5298224bfb34096b2c8667b420fe8ebd8fe54645aeec880a48a

See more details on using hashes here.

File details

Details for the file ipcs-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: ipcs-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 15.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.11

File hashes

Hashes for ipcs-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9582a2d14be8da48a5541e7bb6999308196f3ec0afe47d30bc1bdb3f47d634e7
MD5 59752e99d16b22df2bc4007dd563a08e
BLAKE2b-256 fb99348b3d69b6e2c9cd6cd0456807fca98301a056f86dee2d3868aa83ad7479

See more details on using hashes here.

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