|
|
hai 7 meses | |
|---|---|---|
| .. | ||
| src | hai 7 meses | |
| .gitignore | hai 1 ano | |
| Cargo.toml | hai 7 meses | |
| Makefile | %!s(int64=3) %!d(string=hai) anos | |
| README.md | %!s(int64=3) %!d(string=hai) anos | |
| pyproject.toml | hai 9 meses | |
Python bindings for some parts of the darkfi-sdk and the zkvm.
maturin via your package manager or from source.make to build the wheelFor a development version you can use a venv:
$ python3 -m venv venv
$ source venv/bin/activate
(venv) $ make dev
$ python
>>> import darkfi_sdk
>>> from darkfi_sdk.pasta import Fp
>>> a = Fp.from_u64(42)
>>> b = Fp.from_u64(69)
>>> a + b == Fp.from_u64(111)
Note that the random methods take randomness
from the OS on the Rust side.