Serialized length is now statically computed depending on the domain
size.
Opens the primitive to more generic usages not related to Sassafras
expectations
Address one point of
https://github.com/paritytech/polkadot-sdk/issues/2364
Using taplo, fixes all our broken and inconsistent toml formatting and
adds CI to keep them tidy.
If people want we can customise the format rules as described here
https://taplo.tamasfe.dev/configuration/formatter-options.html
@ggwpez, I suggest zepter is used only for checking features are
propagated, and leave formatting for taplo to avoid duplicate work and
conflicts.
TODO
- [x] Use `exclude = [...]` syntax in taplo file to ignore zombienet
tests instead of deleting the dir
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Bastian Köcher <git@kchr.de>
This moves the macro related re-exports to `__private` to make it more
obvious for downstream users that they are using an internal api.
---------
Co-authored-by: command-bot <>
BEEFY ECDSA signatures are on keccak has of the messages. As such we can
not simply call
`EcdsaBlsPair::verify(signature.as_inner_ref(), msg,
self.as_inner_ref())`
because that invokes ecdsa default verification which perfoms blake2
hash which we don't want.
This bring up the second issue makes: This makes `sign` and `verify`
function in `pair_crypto` useless, at least for BEEFY use case.
Moreover, there is no obvious clean way to generate the signature given
that pair_crypto does not exposes `sign_prehashed`. You could in theory
query the keystore for the pair (could you?), invoke `to_raw` and
re-generate each sub-pair and sign using each. But that sounds extremely
anticlimactic and will be frow upon by auditors . So I appreciate any
alternative suggestion.
---------
Co-authored-by: Davide Galassi <davxy@datawok.net>
Co-authored-by: Robert Hambrock <roberthambrock@gmail.com>
Remove the `GRANDPA_AUTHORITIES_KEY` key and its usage. Apparently this
was used in the early days to communicate the grandpa authorities to the
node. However, we have now a runtime api that does this for us. So, this
pull request is moving from the custom managed storage item to a FRAME
managed storage item.
This pr also includes a migration for doing the switch on a running
chain.
---------
Co-authored-by: Davide Galassi <davxy@datawok.net>
Next step in process of making BEEFY being able to generate both ECDSA
and BLS signature after #1705. It allows BEEFY to use a pair of ECDSA
and BLS key as a AuthorityId.
---------
Co-authored-by: Davide Galassi <davxy@datawok.net>
Co-authored-by: Robert Hambrock <roberthambrock@gmail.com>
Adds a config file that allows to run `zepter` without any arguments in
the workspace to address all issues.
A secondary workflow for the CI is provided as `zepter run check`. Both
the formatting and linting are now in one check for efficiancy.
The latest version also detects some more things that `featalign` was
already showing.
Error message [in the
CI](https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/3916205)
now looks like this:
```pre
...
crate 'test-parachains' (/Users/vados/Documents/work/polkadot-sdk/polkadot/parachain/test-parachains/Cargo.toml)
feature 'std'
must propagate to:
parity-scale-codec
Found 55 issues (run with --fix to fix).
Error: Command 'lint propagate-feature' failed with exit code 1
Polkadot-SDK uses the Zepter CLI to detect abnormalities in the feature configuration.
It looks like one more more checks failed; please check the console output. You can try to automatically address them by running `zepter`.
Otherwise please ask directly in the Merge Request, GitHub Discussions or on Matrix Chat, thank you.
For more information, see:
- https://github.com/paritytech/polkadot-sdk/issues/1831
- https://github.com/ggwpez/zepter
```
TODO:
- [x] Check that CI fails correctly
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
The `xcm` crate was renamed to `staging-xcm` to be able to publish it to
crates.io as someone as squatted `xcm`. The problem with this rename is
that the `TypeInfo` includes the crate name which ultimately lands in
the metadata. The metadata is consumed by downstream users like
`polkadot-js` or people building on top of `polkadot-js`. These people
are using the entire `path` to find the type in the type registry. Thus,
their code would break as the type path would now be [`staging_xcm`,
`VersionedXcm`] instead of [`xcm`, `VersionedXcm`]. This pull request
fixes this by renaming the path segment `staging_xcm` to `xcm`.
This requires: https://github.com/paritytech/scale-info/pull/197
---------
Co-authored-by: Francisco Aguirre <franciscoaguirreperez@gmail.com>
When detecting pallet-beefy consensus reset, just reinitialize the worker
and continue without bringing down the task (and possibly the node).
Signed-off-by: Adrian Catangiu <adrian@parity.io>
* Merged BEEFY primitives with generic signature and keyset commitment support from old pull to current code
* - Add bls-experimental feature to application-crypto and beefy primitives
- Fix remaining crypto -> ecdsa_crypto
- code build but not tests
* Make beefy primitive tests compile
* move bls related beefy primitives code and test behind bls-experimental flag
* Make BEEFY clients complies with BEEFY API depending on AuthorityId
* - Rename `BeefyAuthoritySet.root` → `BeefyAuthoritySet.keyset_commitment`.
- Remove apk proof keyset_commitment from `BeefyAuthoritySet`.
- Fix failing signed commitment and signature to witness test.
- Make client compatible with BeefyAPI generic on AuthorityId.
- `crypto` → `ecdsa_crypto` in BEEFY client and frame.
* Commit Cargo lock remove ark-serialize from BEEFY primitives
* Use Codec instead of Encode + Decode in primitives/consensus/beefy/src/lib.rs
Co-authored-by: Davide Galassi <davxy@datawok.net>
* - Make `BeefyApi` generic over Signature type.
- Make new `BeeyApi` functinos also generic over AuthorityId and Signature
* Unmake BeefyAPI generic over Signature. Recover Signature type from AuthId.
* - dont use hex or hex-literal use array-bytes instead in beefy primitives and bls crypto.
- CamelCase ECDSA and BLS everywhere.
* Move the definition of BEEFY key type from `primitives/beefy` to `crypto.rs` according to new convention.
* - Add bls377_generate_new to `sp-io` and `application_crypto::bls`.
- Add `bls-experimental` to `sp-io`
Does not compile because PassByCodec can not derive PassBy using customly implemented PassByIner.
* Implement PassBy for `bls::Public` manually
* fix Beefy `KEY_TYPE` in `frame/beefy` tests to come from `sp-core::key_types` enum
* specify both generic for `hex2array_unchecked` in `sp-core/bls.rs`
* Rename `crypto`→`ecdsa_crypto` in `primitives/consensus/beefy/src/test_utils.rs` docs
* remove commented-out code in `primitives/consensus/beefy/src/commitment.rs`
Co-authored-by: Davide Galassi <davxy@datawok.net>
* Fix inconsistency in panic message in `primitives/io/src/lib.rs`
Co-authored-by: Davide Galassi <davxy@datawok.net>
* Remove redundant feature activation in `primitives/io/Cargo.toml`
Co-authored-by: Davide Galassi <davxy@datawok.net>
* - make `w3f-bls` a dev-dependancy only for beefy primitives.
- clean up comments.
Co-authored-by: Davide Galassi <davxy@datawok.net>
* export BEEFY KEY_TYPE from primitives/consensus/beefy
make `frame/consensus/beefy` in dependent of sp_crypto_app
use consistent naming in the beefy primitive tests.
* - implement `BeefyAuthorityId` for `bls_crypto::AuthorityId`.
- implement `bls_verify_works` test for BEEFY `bls_crypto`.
* Remove BEEFY `ecdsa_n_bls_crypto` for now for later re-introduction
* Make commitment and witness BEEFY tests not use Keystore.
* put `bls_beefy_verify_works` test under `bls-experimental` flag.
* bump up Runtime `BeefyAPI` to version 3 due to introducing generic AuthorityId.
* reuse code and encapsulate w3f-bls backend in sp-core as most as possible
Co-authored-by: Davide Galassi <davxy@datawok.net>
* Make comments in primities BEEFY `commitment.rs` and `witness.rs``tests convention conforming
* Use master dep versions
* Trivial change. Mostly to trigger CI
* Apply suggestions from code review
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com>
* Fix Cargo.toml
* Trigger CI with cumulus companion
* Trigger CI after polkadot companion change
---------
Co-authored-by: Davide Galassi <davxy@datawok.net>
Co-authored-by: André Silva <123550+andresilva@users.noreply.github.com>
* Fix std, runtime-benchmarks and try-runtime features
zepter lint propagate-feature --feature try-runtime --left-side-feature-missing=ignore --workspace --fix --feature-enables-dep="try-runtime:frame-try-runtime"
zepter lint propagate-feature --feature runtime-benchmarks --left-side-feature-missing=ignore --workspace --fix --feature-enables-dep="runtime-benchmarks:frame-benchmarking"
zepter lint propagate-feature --feature std --left-side-feature-missing=ignore --workspace --fix
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Add propagate feature CI check
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Test CI by adding an error
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Use --locked
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Add help msg
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Revert "Test CI by adding an error"
This reverts commit cf4ff6cc0632269b0a109e547686e5e3314b02de.
* Test CI by adding an error
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* No newline in help msg
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Revert "Test CI by adding an error"
This reverts commit 5daa06ada8e01f5bebafb9d1c76804dd79bc1006.
* Test CI by adding an error
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Revert "Test CI by adding an error"
This reverts commit ca15de5729507a564f140a10ec2e87b19516ec4c.
* Fix msg
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Revert back to master
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Re-do with Zepter v0.7.4
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Update Zepter to 0.7.4
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Disable rococo try-runtime check
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Apply suggestions from code review
Co-authored-by: Bastian Köcher <git@kchr.de>
* More review fixes
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Bastian Köcher <git@kchr.de>
* Start
* More work!
* Moar
* More changes
* More fixes
* More worrk
* More fixes
* More fixes to make it compile
* Adds `NoOffchainStorage`
* Pass the extensions
* Small basti making small progress
* Fix merge errors and remove `ExecutionContext`
* Move registration of `ReadRuntimeVersionExt` to `ExecutionExtension`
Instead of registering `ReadRuntimeVersionExt` in `sp-state-machine` it is moved to
`ExecutionExtension` which provides the default extensions.
* Fix compilation
* Register the global extensions inside runtime api instance
* Fixes
* Fix `generate_initial_session_keys` by passing the keystore extension
* Fix the grandpa tests
* Fix more tests
* Fix more tests
* Don't set any heap pages if there isn't an override
* Fix small fallout
* FMT
* Fix tests
* More tests
* Offchain worker custom extensions
* More fixes
* Make offchain tx pool creation reusable
Introduces an `OffchainTransactionPoolFactory` for creating offchain transactions pools that can be
registered in the runtime externalities context. This factory will be required for a later pr to
make the creation of offchain transaction pools easier.
* Fixes
* Fixes
* Set offchain transaction pool in BABE before using it in the runtime
* Add the `offchain_tx_pool` to Grandpa as well
* Fix the nodes
* Print some error when using the old warnings
* Fix merge issues
* Fix compilation
* Rename `babe_link`
* Rename to `offchain_tx_pool_factory`
* Cleanup
* FMT
* Fix benchmark name
* Fix `try-runtime`
* Remove `--execution` CLI args
* Make clippy happy
* Forward bls functions
* Fix docs
* Update UI tests
* Update client/api/src/execution_extensions.rs
Co-authored-by: Michal Kucharczyk <1728078+michalkucharczyk@users.noreply.github.com>
* Apply suggestions from code review
Co-authored-by: Koute <koute@users.noreply.github.com>
* Update client/cli/src/params/import_params.rs
Co-authored-by: Koute <koute@users.noreply.github.com>
* Update client/api/src/execution_extensions.rs
Co-authored-by: Koute <koute@users.noreply.github.com>
* Pass the offchain storage to the MMR RPC
* Update client/api/src/execution_extensions.rs
Co-authored-by: Sebastian Kunert <skunert49@gmail.com>
* Review comments
* Fixes
---------
Co-authored-by: Michal Kucharczyk <1728078+michalkucharczyk@users.noreply.github.com>
Co-authored-by: Koute <koute@users.noreply.github.com>
Co-authored-by: Sebastian Kunert <skunert49@gmail.com>
`Hash` is no longer part of `pallet_mmr::Config`, but this code
would still build because it assumes we're referring to underlying
`<pallet_mmr::Config as frame_system::Config>::Hash` which is not
what we want when using different hashing between `frame_system`
and `pallet_mmr`.
Disambiguate by using correct `pallet_mmr::Config::Hashing` type.
Signed-off-by: acatangiu <adrian@parity.io>
This is followup of #13027.
`Aura` need to enable `serde` feature in dependent crates, otherwise
test-substrate-runtime compilation fails with the following error if
`serde` is enabled:
```
error: cannot find macro `format` in this scope
-->
/home/miszka/parity/10-genesis-config/substrate-master/primitives/consensus/aura/src/lib.rs:50:3
|
50 | app_crypto!(ed25519, AURA);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: consider importing one of these items:
scale_info::prelude::format
sp_application_crypto::format
= note: this error originates in the macro
`$crate::app_crypto_public_common_if_serde` which comes from the
expansion of the macro `app_crypto` (in Nightly builds, run with -Z
macro-backtrace for more info)
```
* add serde_full feature flag
add serde_full to sp_runtime
add space to toml
add serde_full to application-crypto
add serde_full to arithmetic
fix arithmetic
add serde full to beefy
add serde full to consensus
add serde_full to core
add serdefull to finality grandpa
add serde_full to several primitives crates
make rpc no_std compatible
add scale info to runtime
make serializer no_std compatible
add serde full to storage
add full serde to version
add serde full to weights
add all serde_full features
add . to comment
add missing impl-serde
fix no-std build
fix build
add full_crypto to serde_full
serde_full also implements crypto
full_serde does not work with full_crytpo. needs std
no no_std serde impl possible
also for crypto std is necessary
no serde full for application crypto
fix arithmetic
fix tomls
fix some things
impl fmt for Signature
add serialize to Public
add impl_maybe_marker_serde_full
fix sp-application-crypto toml
add serde feature flag
fix clippy
fix toml grandpa
fix grandpa
rename if_std to if_serde
keystore is not no_std compatible
make keystore vrf no_std compatible
fix nopos-elections
fix rpc
fix serializer
fix test-primitives
fix version
add comment
add serde full only import for format string
remove all(serde_full and full_crypot) as serde_full enforces full_crypto
make comment better readable
even better comment
clean up rpc toml
clean up toml
clean up serializer toml
clean up storage toml
fix std build
update .lock
fix sp-version
move sp_std import
test extern crate alloc
replace sp_std with core
add missing core
sp_core: serde feature do not enforce full crypto
application-crypto: serde feature do not enforce full crypto
rename serde_full to serde
add dep:serde and alloc to default feature
add full_crypto and remove unnecessary debu/fmt impls for serde
update comment
remove obolsete change in display AccountId32
remove extra changes
minimize diff
revert keystore changes
remove std from keystore
remove full-crypto feature
fix serde import
fix comment
fix feature = serde
* rename serde_full to serde
* move #[doc(hidden)] back
* remove feature = full crypto require frm MultiSigner
* reorder serde and scale_info import
* fix bs58 missing alloc import in serde feature
* add `from_string` to serde feature and add unimplemented
* remove serde feature from fixed_point display
* Remove serde/alloc
Co-authored-by: Davide Galassi <davxy@datawok.net>
* Update primitives/consensus/babe/Cargo.toml
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/arithmetic/src/fixed_point.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* revert `from_string`fixed impl back to std only
* remove duplicate runtime string impl
* use sp_std::alloc
* remove no_std compatible rpc
* remove no_std compatibility from serializer
* rename mpl_maybe_marker_serde to std_or_serde
* update .lock
* add sp-std to executor
* fix sp-std import
* fix sp_std::format import
* use crate import
* add serde feature
* Update primitives/core/src/lib.rs
---------
Co-authored-by: Davide Galassi <davxy@datawok.net>
Co-authored-by: Bastian Köcher <git@kchr.de>
* Allow extra signing data
* Fix tests after renaming
* Rename VrfSecret/VrfVerifier to VrfSecret/VrfPublic
* Further encrapsulation of 'transcript' type to the sr25519 implementation
* Keystore sr25519 pre-output
* Leave additional custom input field hidden in the associated VrfInput type
* Fix test
* More ergonomic output_bytes
* Trigger pipeline
* Define a separated type for vrf signature data
* Fix docs
* Fix doc
* Remove annotation
* Directly use dleq_proove and dleq_verify in sr25519
* Trigger CI
* Remove cruft before merge
* First iteration to encapsulate schnorrkel and merlin usage
* Remove schnorkel direct dependency from BABE pallet
* Remove schnorrkel direct dependency from BABE client
* Trivial renaming for VrfTranscript data and value
* Better errors
* Expose a function to get a schnorrkel friendly transcript
* Keep the vrf signature stuff together (preventing some clones around)
* Fix tests
* Remove vrf agnostic transcript and define it as an associated type for VrfSigner and VrfVerifier
* Fix babe pallet mock
* Inner types are required to be public for polkadot
* Update client/consensus/babe/src/verification.rs
Co-authored-by: Koute <koute@users.noreply.github.com>
* Nit
* Remove Deref implementations
* make_bytes as a method
* Trigger CI
---------
Co-authored-by: Koute <koute@users.noreply.github.com>
* impl_runtime_apis: Generate getters for `metadata_at` functions
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* runtime: Implement new `Metadata` runtime trait
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* runtime: Move `metadata_at` functions to construct_runtime macro
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* contruct_runtime: Use `OpaqueMetadata` from hidden imports
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Adjust testing
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/tests: Add tests for the new API
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Helper to extract documentation literals
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Helper to filter all `cfg` attributes
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Generate documentation getters for metadata
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Avoid trait collision with snake case methods
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* proc-macro/tests: Check doc getters
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Generate metadata for runtime methods
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/api: Export scale-info and frame-metadata
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Generate metadata for runtime traits
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/runtime: Expose metadata v15 internally
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* test: Use metadata v15 from `lexnv/md_v15_test` branch
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Generate crate access one module up
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame: Implement `runtime_metadata` for mocks and tests
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Fix warnings
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Add no-docs flag
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame: Adjust more tests
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/tests: Check runtime metadata correctness
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/benchmarking: Adjust benchmarks
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/benchmarks: Adjust more benchmarks
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/api: Fix clippy
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/proc-macro: Generate runtime metadata on the `decl_runtime_apis`
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame: Abuse Deref to resolve `runtime_metadata`
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Revert "frame: Implement `runtime_metadata` for mocks and tests"
This reverts commit b7f41aa189218589392a6e713ea9488e93c4db45.
Revert "frame: Adjust more tests"
This reverts commit 3cba5982c7f45552e76335e96c430aecbc42d8c6.
Revert "frame/benchmarking: Adjust benchmarks"
This reverts commit 60b382ada486c791ffceeb65da587e949b90ec5d.
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Revert "frame/benchmarks: Adjust more benchmarks"
This reverts commit eb75c477179b1a27347a5554c5732ef26a00d7e8.
* primitives/proc-macro: Remove unused imports and function
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/support: Adjust runtime metadata test
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/tests: Remove doc getter test
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/support: Enable `no-metadata-docs` feature from `sp-api`
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/tests: Add `TypeInfo` for test::extrinsic
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/api: Expose scale-info and frame-metadata
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Update frame-metadata to include v15
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Fix merge conflicts
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/metadata_ir: Add IR for runtime API metadata
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/metadata_ir: Convert IR to V15
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/api: Collect IR metadata for runtime API
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/api: Move `metadata_ir` from frame/support
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/tests: Adjust testing
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame/tests: Adjust `metadata_versions` test
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/runtime_metadata: Exclude default type parameters from methods
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Update primitives/api/proc-macro/src/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/src/metadata_ir/types.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/src/metadata_ir/mod.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/proc-macro/src/utils.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/proc-macro/src/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/proc-macro/src/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/proc-macro/src/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/proc-macro/src/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/proc-macro/src/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/proc-macro/src/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* primitives: Fix build
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives/metadata-ir: Move IR to dedicated crate
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives: Reexport metadata-ir and frame-metadata
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* frame: Use apis field instead of runtime
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Better documentation for the `Deref` abstraction
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* ui-tests: Check empty `impl_runtime_apis`
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives: Remove unneeded bounds on generic params
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives: Rename `collect_where_bounds` to `get_argument_type_param`
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives: Generate crate access per fn call
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Revert "primitives: Remove unneeded bounds on generic params"
This reverts commit 5178e38cf21cfb481156eefd628d62989201d59a.
* metadata-ir: Add no-std
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* primitives: Adjust where bounds
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Change `frame-metadata` branch to "origin/main"
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Update to `main` from origin
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Update frame-metadata to crates.io v15.1
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Revert "ui-tests: Check empty `impl_runtime_apis`"
This reverts commit cf78a7190ad9cba3c3bb2e78dc3d0dc382b2fea9.
* Move ui test to primitives/ui
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Update frame/support/test/tests/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Update primitives/api/proc-macro/src/runtime_metadata.rs
Co-authored-by: Bastian Köcher <git@kchr.de>
* Test already covered by `empty_impl_runtime_apis_call.stderr`
This reverts commit 3bafb294cbe9745569bf5e5a1a2e6b4a4c1aadc5.
* Retriger CI
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
* Import `TokenStream` as `TokenStream2`
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
---------
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: parity-processbot <>
Co-authored-by: Bastian Köcher <git@kchr.de>
* Introduce keystore specialized sign methods
* Get rid of 'AppKey::UntypedGeneric' associated type.
Untyped generics are accessible using associated types 'Generic' associated type.
I.e. <T as AppKey>::Public::Generic
* Get rid of 'CryptoTypePublicPair'
* Trivial fix
* Small refactory of local keystore implementations
* Remove 'crypto_id' method from 'Public'
* Trivial rename of 'AppKey' to 'AppCrypto'
* Remove unused import
* Improve docs
* Better signature related errors for authority-discovery
* Apply review suggestion
* Apply review suggestions
Co-authored-by: Koute <koute@users.noreply.github.com>
* Authority discoverty signing error revisited
* Signing error revisited for babe and aura as well
* Further cleanup
---------
Co-authored-by: Koute <koute@users.noreply.github.com>
* Experiments with common equivocation trait
* Improved equivocation trait
* Fix grandpa equivocation implementation
* Remove some cruft
* Remove some more cruft
* More generic naming
* Simplification of offences manipilation
* More refactory
* Some prograss with the encapsulation of offence report system
* Finally unit type works as a universal null report system
* Align substrate node code
* Further simplification
* Fix test utils
* Remove not required associated type
* Fix benches
* Rollback to prev field name
* Box big params
* Fix typo
* Remove new tag computation
* Remove default implementations
* Better docs
* Return 'Result' instead of bool
* Change offence report system return types
* Some renaming and documentation
* Improve documentation
* More abstract offence report system
* Rename 'consume_evidence' to 'process_evidence'
* Further docs refinements
* Doc for dummy offence report
* Fix rustdoc
* Fix after master merge
* Apply code review suggestions
* Improve docs