Ocote
Ocote is a library built on flask allowing for a socket like connection with encryption to a flask sever.
Installation
pip install ocote
Usage
You need to setup a client side and a server side for example:
Client side:
import ocote.ocote as ocote
conn = ocote.connect("localhost:8000", "API_KEY")
conn.ping() # health check -> True/False
print(conn.func("add", 3, 4).value()) # call with args -> 7
print(conn.variable("my_data").value()) # fetch variable -> {"x": 42}
conn.object("cfg") # fetch via pickle -> RemoteResult
add = conn.lazy_func("add") # get a local callable proxy
print(add(10, 20).value()) # -> 30
Server side:
import ocote.ocote as ocote
def add(a, b):
return a + b
my_data = {"x": 42}
class Config:
debug = True
srv = ocote.server()
srv.expose(
funcs={"add": add},
vars={"my_data": my_data},
objects={"cfg": Config()}
)
srv.post("localhost:8000", api_key="API_KEY")
Metadata
Release files for ocote 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| ocote-0.2.0.tar.gz | 62.9 kB | Without provenance | Details for ocote-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ocote-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for ocote-0.2.0-py3-none-any.whl |
Total release size: 71.3 kB
Release files / ocote-0.2.0.tar.gz
| Download URL | ocote-0.2.0.tar.gz |
|---|---|
| Size | 62.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a1e7ceab7c12d19347970338691fc0795448520eda6d153f3b7c56650757b306
|
|
BLAKE2b-256 checksum How to use checksums |
a5710bfc55ab65d6f45074fcc1f546362637048b4602ae6d920500d24f15d368
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.4
|
Release files / ocote-0.2.0-py3-none-any.whl
| Download URL | ocote-0.2.0-py3-none-any.whl |
|---|---|
| Size | 8.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
84953f37d0a799e465fdc0e204f112885cf7d81739c090bc5d58002abf54bce8
|
|
BLAKE2b-256 checksum How to use checksums |
b27a61e53604517c09eb57040bce38b9e8eb2cdd47186a744b6d5e4c7ed9e7fc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.4
|
Security for ocote 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.