semvec/pypi-packages huggingface dataset:
jsonrpc-pyclient 1.1.3
A transport-agnostic json-rpc client library
License: MIT
Keywords: rpc json json-rpc

jsonrpc_pyclient
================
jsonrpc_pyclient is a transport-agnostic json-rpc 2.0 and 1.0 client library primarily intended for use with
libjson-rpc-cpp_ but can be used with other json-rpc server implementations.

.. _libjson-rpc-cpp: https://github.com/cinemast/libjson-rpc-cpp

This library is intended to be used with libjson-rpc-cpp's stubgenerator,
which takes a json-formatted specification file, and can then return server
and client stubs in various languages; the python client stub generator was
created to use this library. For more information on using the stubgenerator,
refer to libjson-rpc-cpp's documentation.

Currently Supported Transports
------------------------------
- http
- tcp sockets


Basic Usage
-----------
.. code-block:: python

    >>> from jsonrpc_pyclient.connectors import socketclient
    >>> import ClientStub #client stub created by libjson-rpc-cpp stubgenerator
    >>> connector = socketclient.TcpSocketClient("127.0.0.1", 8032)
    >>> client = ClientStub(connector)
    >>> result = client.addNumbers(4, 5)
    >>> print(result)


Installation
------------
.. code-block:: bash

    $ pip install jsonrpc_pyclient
deasync 1.0.1
deasync decorator to make async functions/methods synchronous.
License: MIT
Keywords: async await deasync desynchronize

deasync provides a decorator called `deasync` for Python 3.5 (or higher) to make async functions synchronous in places where only synchronous functions are expected, for example in `unittest.TestCase`:

.. code:: python

    from asyncio import sleep
    from unittest import TestCase
    from deasync import deasync


    async def function42():
        await sleep(0.001)
        return 42


    class TestFunction42(TestCase):
        @deasync
        async def test_function42(self):
            result = await function42()
            self.assertEquals(42, result)