jammy.concurrency package

Submodules

jammy.concurrency.packing module

jammy.concurrency.packing.check_msgpack()[source]
jammy.concurrency.packing.check_pickle()[source]
jammy.concurrency.packing.check_pyarrow()[source]
jammy.concurrency.packing.dumpb(obj, *args, backend=None, **kwargs)[source]
jammy.concurrency.packing.dumpb_pickle(obj, protocol=None, *, fix_imports=True)

Return the pickled representation of the object as a bytes object.

The optional protocol argument tells the pickler to use the given protocol; supported protocols are 0, 1, 2, 3 and 4. The default protocol is 3; a backward-incompatible protocol designed for Python 3.

Specifying a negative protocol version selects the highest protocol version supported. The higher the protocol used, the more recent the version of Python needed to read the pickle produced.

If fix_imports is True and protocol is less than 3, pickle will try to map the new Python 3 names to the old module names used in Python 2, so that the pickle data stream is readable with Python 2.

jammy.concurrency.packing.get_available_backends()[source]
jammy.concurrency.packing.get_default_backend()[source]
jammy.concurrency.packing.loadb(bstr, *args, backend=None, **kwargs)[source]
jammy.concurrency.packing.loadb_pickle(data, *, fix_imports=True, encoding='ASCII', errors='strict')

Read and return an object from the given pickle data.

The protocol version of the pickle is detected automatically, so no protocol argument is needed. Bytes past the pickled object’s representation are ignored.

Optional keyword arguments are fix_imports, encoding and errors, which are used to control compatibility support for pickle stream generated by Python 2. If fix_imports is True, pickle will try to map the old Python 2 names to the new names used in Python 3. The encoding and errors tell pickle how to decode 8-bit string instances pickled by Python 2; these default to ‘ASCII’ and ‘strict’, respectively. The encoding can be ‘bytes’ to read these 8-bit string instances as bytes objects.

jammy.concurrency.packing.set_default_backend(backend)[source]

jammy.concurrency.zmq_utils module

jammy.concurrency.zmq_utils.bind_to_random_ipc(sock, name)[source]
jammy.concurrency.zmq_utils.graceful_close(sock)[source]
jammy.concurrency.zmq_utils.iter_recv(meth, sock)[source]
jammy.concurrency.zmq_utils.json_dumpb(x)
jammy.concurrency.zmq_utils.json_loadb(x)
jammy.concurrency.zmq_utils.pull_pyobj(sock, flag=1)[source]
jammy.concurrency.zmq_utils.push_pyobj(sock, data, flag=1)[source]
jammy.concurrency.zmq_utils.req_recv_json(sock, flag=0, loader=<function <lambda>>)[source]
jammy.concurrency.zmq_utils.req_send_and_recv(sock, *payloads)[source]
jammy.concurrency.zmq_utils.req_send_json(sock, *payloads, flag=0, dumper=<function <lambda>>)[source]
jammy.concurrency.zmq_utils.router_recv_json(sock, flag=1, loader=<function <lambda>>)[source]
jammy.concurrency.zmq_utils.router_send_json(sock, identifier, *payloads, flag=0, dumper=<function <lambda>>)[source]
jammy.concurrency.zmq_utils.uid()[source]

Module contents

jammy.concurrency.bind_to_random_ipc(sock, name)[source]
jammy.concurrency.graceful_close(sock)[source]
jammy.concurrency.iter_recv(meth, sock)[source]
jammy.concurrency.json_dumpb(x)
jammy.concurrency.json_loadb(x)
jammy.concurrency.pull_pyobj(sock, flag=1)[source]
jammy.concurrency.push_pyobj(sock, data, flag=1)[source]
jammy.concurrency.req_recv_json(sock, flag=0, loader=<function <lambda>>)[source]
jammy.concurrency.req_send_and_recv(sock, *payloads)[source]
jammy.concurrency.req_send_json(sock, *payloads, flag=0, dumper=<function <lambda>>)[source]
jammy.concurrency.router_recv_json(sock, flag=1, loader=<function <lambda>>)[source]
jammy.concurrency.router_send_json(sock, identifier, *payloads, flag=0, dumper=<function <lambda>>)[source]
jammy.concurrency.uid()[source]