Skip to content
Snippets Groups Projects
Commit c8007705 authored by Hugo Trentesaux's avatar Hugo Trentesaux
Browse files

wip

parent ca8c9320
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !101. Comments created here will be created in the context of that merge request.
......@@ -20,7 +20,7 @@
- [docs](./docs/)
- [api](./docs/api/)
- [manual](./docs/api/manual.md)
- [runtime-calls](./docs/api/runtime-calls.md)
- [runtime-calls](./docs/api/runtime-calls.md) the calls you can submit through the RPC API
- [dev](./docs/dev/)
- [git-conventions](./docs/dev/git-conventions.md)
- [launch-a-live-network](./docs/dev/launch-a-live-network.md)
......
# Manual for wallet developers
This functionnal documentation presents how wallets can interact with the blockchain.
This functional documentation presents how wallets can interact with the blockchain.
It is intended to complete the [runtime calls documentation](./runtime-calls.md) in a runtime-specific way to fit the real needs of wallet developers.
Only ĞDev is covered for now.
......@@ -23,9 +23,9 @@ Only use `identity` pallet. The `membership` calls are disabled.
## Revoke an identity
Revoking an identity makes it lose its membership, hence UD creation and governance rights. Orher data such as balance will remain.
Revoking an identity makes it lose its membership, hence UD creation and governance rights. Other data such as balance will remain.
This feature is useful in case the user has lost their private key.
This feature is useful in case the user has lost their private key since the revocation document can be made in advance.
### Generate the revocation payload
......
......@@ -2,7 +2,7 @@
## 1. Choose the currency type
Ensure that the currency type you want have the requirements.
Ensure that the currency type you want has the requirements.
For now, only `gdev` is supported.
......
# Compile the runtime with srtool
When voting for a runtime upgrade, you should check that the proposed sha256sum actually corresponds to the published code you reviewed. Otherwise, a malicious runtime upgrade could be advertised as a legitimate one.
```docker
docker run \
-i \
......
......@@ -6,22 +6,22 @@ complete real example.
`cargo test -p <pallet> --features runtime-benchmarks`
3. If the benchmark tests compiles and pass, compile the binary with benchmarks on your local
machine: `cargo build --release --features runtime-benchmarks`
4. Run the benchmarks on your local machine (to test if it work mith a real runtime). The command
4. Run the benchmarks on your local machine (to test if it work with a real runtime). The command
is: `duniter benchmark pallet --chain=CURRENCY-dev --steps=50 --repeat=20 --pallet=pallet_universal_dividend --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=.`
5. If it work, use the generated file content to create or update the `WeightInfo` trait and the `()` dummy implementation. Then use the `WeightInfo` tarit in the real code of the pallet. See 79e0fd4bf3b0579279fc957da5e2fdfc6d8a17fa for a
5. If it worked, use the generated file content to create or update the `WeightInfo` trait and the `()` dummy implementation. Then use the `WeightInfo` tarit in the real code of the pallet. See 79e0fd4bf3b0579279fc957da5e2fdfc6d8a17fa for a
complete real example.
6. Redo steps `3.` and `4.` on the reference machine.
7. Put the generated file on `runtime/common/src/weights` and use it in the runtimes configuration.
See cee7c3b2763ba402e807f126534d9cd39a8bd025 for a complete real example.
Note 1: You Must replace `CURRENCY` by the currency type, or for ĞDev use directly `--chain=dev`.
Note 1: You *must* replace `CURRENCY` by the currency type, or for ĞDev use directly `--chain=dev`.
Note2. If the reference machine not support wasmtime, you should replace `--wasm-execution=compiled`
Note 2: If the reference machine does not support wasmtime, you should replace `--wasm-execution=compiled`
by `--wasm-execution=interpreted-i-know-what-i-do`.
## What the reference machine is?
## What is the reference machine?
For now (06/2022), it's a `Raspberry Pi 4 Model B - 4GB` with an SSD connected via USB3.
For now (09/2022), it's a `Raspberry Pi 4 Model B - 4GB` with an SSD connected via USB3.
To cross-compile the benchmarks binary for armv7:
......
# Duniter-v2s end2end tests
## Cucumber functionnal tests
## Cucumber functional tests
We use [cucumber] to be able to describe test scenarios in human language.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment