Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 22 additions & 0 deletions frame/account-mapping/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Changelog

All notable changes to `pallet-account-mapping` will be documented in this file.

## [0.2.1] - 2026-05-22

### Changed

- Updated FRAME benchmark weights measured on Hetzner CCX33 (AMD EPYC-Milan, 8 vCPU dedicated, 32 GB RAM). Steps: `50`, Repeat: `20`. All 16 extrinsics refreshed.

### Fixed

- `benchmarking.rs`: replaced `T::AccountId: From<[u8; 32]>` bound (which broke compilation in mock runtimes with `type AccountId = u64`) with a `scale_codec::Decode`-based helper. The `evm_account<T>()` function now decodes a 32-byte slice into `T::AccountId` without requiring the `From<[u8; 32]>` trait bound.

## [0.2.0] - 2026-05-14

### Added

- Initial tracked release.
- EVM ↔ Substrate account mapping via `AccountMapping` storage.
- `link_evm_address` and `unlink_evm_address` extrinsics.
- Full benchmark and weight coverage.
2 changes: 1 addition & 1 deletion frame/account-mapping/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "pallet-account-mapping"
version = "0.2.0"
version = "0.2.1"
license = "Apache-2.0"
description = "Stateful mapping between Substrate AccountId32 and EVM H160 addresses, with alias registration and multichain identity support."
authors = { workspace = true }
Expand Down
769 changes: 736 additions & 33 deletions frame/account-mapping/src/weights.rs

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions frame/relayer/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

All notable changes to `pallet-relayer` will be documented in this file.

## [0.2.1] - 2026-05-22

### Changed

- Updated FRAME benchmark weights measured on Hetzner CCX33 (AMD EPYC-Milan, 8 vCPU dedicated, 32 GB RAM). Steps: `50`, Repeat: `20`. All extrinsics refreshed.

## [0.2.0] - 2026-05-14

### Added
Expand Down
2 changes: 1 addition & 1 deletion frame/relayer/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "pallet-relayer"
version = "0.2.0"
version = "0.2.1"
description = "On-chain relay configuration, relayer registry and fee accounting."
authors = { workspace = true }
license = "GPL-3.0-or-later"
Expand Down
102 changes: 58 additions & 44 deletions frame/relayer/src/weights.rs
Original file line number Diff line number Diff line change
@@ -1,23 +1,33 @@

//! Autogenerated weights for pallet_relayer
//!
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 49.1.0
//! DATE: 2026-04-14, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
//! THIS FILE WAS AUTO-GENERATED USING THE SUBSTRATE BENCHMARK CLI VERSION 53.0.0
//! DATE: 2026-05-22, STEPS: `50`, REPEAT: `20`, LOW RANGE: `[]`, HIGH RANGE: `[]`
//! WORST CASE MAP SIZE: `1000000`
//! HOSTNAME: `MacBook-Air-de-Nolasco.local`, CPU: `<UNKNOWN>`
//! HOSTNAME: `ubuntu-32gb-hil-1`, CPU: `AMD EPYC-Milan Processor`
//! EXECUTION: , WASM-EXECUTION: Compiled, CHAIN: Some("dev"), DB CACHE: 1024

// Executed Command:
// ./target/release/orbinum-node
// benchmark
// pallet
// --chain=dev
// --pallet=pallet_relayer
// --extrinsic=*
// --steps=50
// --repeat=20
// --output=frame/relayer/src/weights.rs
// --template=./scripts/frame-weight-template.hbs
// --chain
// dev
// --pallet
// pallet_relayer
// --extrinsic
// *
// --steps
// 50
// --repeat
// 20
// --execution=wasm
// --wasm-execution=compiled
// --heap-pages=4096
// --output
// ./frame/relayer/src/weights.rs
// --template
// ./scripts/frame-weight-template.hbs

#![cfg_attr(rustfmt, rustfmt_skip)]
#![allow(unused_parens)]
Expand Down Expand Up @@ -52,8 +62,8 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
// Proof Size summary in bytes:
// Measured: `19`
// Estimated: `1504`
// Minimum execution time: 5_000_000 picoseconds.
Weight::from_parts(6_000_000, 1504)
// Minimum execution time: 7_041_000 picoseconds.
Weight::from_parts(7_311_000, 1504)
.saturating_add(T::DbWeight::get().reads(4_u64))
.saturating_add(T::DbWeight::get().writes(3_u64))
}
Expand All @@ -68,19 +78,17 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
/// Storage: `Relayer::AllowedSelectors` (r:0 w:1)
/// Proof: `Relayer::AllowedSelectors` (`max_values`: Some(1), `max_size`: Some(65), added: 560, mode: `MaxEncodedLen`)
/// The range of component `n` is `[0, 16]`.
fn set_allowed_selectors(_n: u32, ) -> Weight {
fn set_allowed_selectors(n: u32, ) -> Weight {
// Proof Size summary in bytes:
// Measured: `19`
// Estimated: `1504`
// Minimum execution time: 5_000_000 picoseconds.
Weight::from_parts(6_021_147, 1504)
// Minimum execution time: 7_162_000 picoseconds.
Weight::from_parts(7_633_535, 1504)
// Standard Error: 790
.saturating_add(Weight::from_parts(9_479, 0).saturating_mul(n.into()))
.saturating_add(T::DbWeight::get().reads(4_u64))
.saturating_add(T::DbWeight::get().writes(3_u64))
}
/// Storage: `Relayer::RelayerRegistry` (r:1 w:1)
/// Proof: `Relayer::RelayerRegistry` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `Relayer::RelayerByAccount` (r:1 w:1)
/// Proof: `Relayer::RelayerByAccount` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `System::Number` (r:1 w:0)
/// Proof: `System::Number` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
/// Storage: `System::ExecutionPhase` (r:1 w:0)
Expand All @@ -89,19 +97,21 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
/// Proof: `System::EventCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
/// Storage: `System::Events` (r:1 w:1)
/// Proof: `System::Events` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
/// Storage: `Relayer::RelayerRegistry` (r:0 w:1)
/// Proof: `Relayer::RelayerRegistry` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `Relayer::RelayerByAccount` (r:0 w:1)
/// Proof: `Relayer::RelayerByAccount` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
fn register_relayer() -> Weight {
// Proof Size summary in bytes:
// Measured: `61`
// Estimated: `3533`
// Minimum execution time: 9_000_000 picoseconds.
Weight::from_parts(9_000_000, 3533)
// Measured: `19`
// Estimated: `1504`
// Minimum execution time: 8_573_000 picoseconds.
Weight::from_parts(8_873_000, 1504)
.saturating_add(T::DbWeight::get().reads(4_u64))
.saturating_add(T::DbWeight::get().writes(4_u64))
}
/// Storage: `Relayer::RelayerByAccount` (r:1 w:1)
/// Proof: `Relayer::RelayerByAccount` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `Relayer::RelayerRegistry` (r:0 w:1)
/// Proof: `Relayer::RelayerRegistry` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `System::Number` (r:1 w:0)
/// Proof: `System::Number` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
/// Storage: `System::ExecutionPhase` (r:1 w:0)
Expand All @@ -110,12 +120,14 @@ impl<T: frame_system::Config> WeightInfo for SubstrateWeight<T> {
/// Proof: `System::EventCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
/// Storage: `System::Events` (r:1 w:1)
/// Proof: `System::Events` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
/// Storage: `Relayer::RelayerRegistry` (r:0 w:1)
/// Proof: `Relayer::RelayerRegistry` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
fn unregister_relayer() -> Weight {
// Proof Size summary in bytes:
// Measured: `189`
// Estimated: `3533`
// Minimum execution time: 12_000_000 picoseconds.
Weight::from_parts(12_000_000, 3533)
// Minimum execution time: 15_603_000 picoseconds.
Weight::from_parts(16_074_000, 3533)
.saturating_add(T::DbWeight::get().reads(5_u64))
.saturating_add(T::DbWeight::get().writes(4_u64))
}
Expand All @@ -137,8 +149,8 @@ impl WeightInfo for () {
// Proof Size summary in bytes:
// Measured: `19`
// Estimated: `1504`
// Minimum execution time: 5_000_000 picoseconds.
Weight::from_parts(6_000_000, 1504)
// Minimum execution time: 7_041_000 picoseconds.
Weight::from_parts(7_311_000, 1504)
.saturating_add(RocksDbWeight::get().reads(4_u64))
.saturating_add(RocksDbWeight::get().writes(3_u64))
}
Expand All @@ -153,19 +165,17 @@ impl WeightInfo for () {
/// Storage: `Relayer::AllowedSelectors` (r:0 w:1)
/// Proof: `Relayer::AllowedSelectors` (`max_values`: Some(1), `max_size`: Some(65), added: 560, mode: `MaxEncodedLen`)
/// The range of component `n` is `[0, 16]`.
fn set_allowed_selectors(_n: u32, ) -> Weight {
fn set_allowed_selectors(n: u32, ) -> Weight {
// Proof Size summary in bytes:
// Measured: `19`
// Estimated: `1504`
// Minimum execution time: 5_000_000 picoseconds.
Weight::from_parts(6_021_147, 1504)
// Minimum execution time: 7_162_000 picoseconds.
Weight::from_parts(7_633_535, 1504)
// Standard Error: 790
.saturating_add(Weight::from_parts(9_479, 0).saturating_mul(n.into()))
.saturating_add(RocksDbWeight::get().reads(4_u64))
.saturating_add(RocksDbWeight::get().writes(3_u64))
}
/// Storage: `Relayer::RelayerRegistry` (r:1 w:1)
/// Proof: `Relayer::RelayerRegistry` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `Relayer::RelayerByAccount` (r:1 w:1)
/// Proof: `Relayer::RelayerByAccount` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `System::Number` (r:1 w:0)
/// Proof: `System::Number` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
/// Storage: `System::ExecutionPhase` (r:1 w:0)
Expand All @@ -174,19 +184,21 @@ impl WeightInfo for () {
/// Proof: `System::EventCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
/// Storage: `System::Events` (r:1 w:1)
/// Proof: `System::Events` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
/// Storage: `Relayer::RelayerRegistry` (r:0 w:1)
/// Proof: `Relayer::RelayerRegistry` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `Relayer::RelayerByAccount` (r:0 w:1)
/// Proof: `Relayer::RelayerByAccount` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
fn register_relayer() -> Weight {
// Proof Size summary in bytes:
// Measured: `61`
// Estimated: `3533`
// Minimum execution time: 9_000_000 picoseconds.
Weight::from_parts(9_000_000, 3533)
// Measured: `19`
// Estimated: `1504`
// Minimum execution time: 8_573_000 picoseconds.
Weight::from_parts(8_873_000, 1504)
.saturating_add(RocksDbWeight::get().reads(4_u64))
.saturating_add(RocksDbWeight::get().writes(4_u64))
}
/// Storage: `Relayer::RelayerByAccount` (r:1 w:1)
/// Proof: `Relayer::RelayerByAccount` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `Relayer::RelayerRegistry` (r:0 w:1)
/// Proof: `Relayer::RelayerRegistry` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
/// Storage: `System::Number` (r:1 w:0)
/// Proof: `System::Number` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
/// Storage: `System::ExecutionPhase` (r:1 w:0)
Expand All @@ -195,12 +207,14 @@ impl WeightInfo for () {
/// Proof: `System::EventCount` (`max_values`: Some(1), `max_size`: Some(4), added: 499, mode: `MaxEncodedLen`)
/// Storage: `System::Events` (r:1 w:1)
/// Proof: `System::Events` (`max_values`: Some(1), `max_size`: None, mode: `Measured`)
/// Storage: `Relayer::RelayerRegistry` (r:0 w:1)
/// Proof: `Relayer::RelayerRegistry` (`max_values`: None, `max_size`: Some(68), added: 2543, mode: `MaxEncodedLen`)
fn unregister_relayer() -> Weight {
// Proof Size summary in bytes:
// Measured: `189`
// Estimated: `3533`
// Minimum execution time: 12_000_000 picoseconds.
Weight::from_parts(12_000_000, 3533)
// Minimum execution time: 15_603_000 picoseconds.
Weight::from_parts(16_074_000, 3533)
.saturating_add(RocksDbWeight::get().reads(5_u64))
.saturating_add(RocksDbWeight::get().writes(4_u64))
}
Expand Down
15 changes: 15 additions & 0 deletions frame/shielded-pool/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,21 @@

All notable changes to `pallet-shielded-pool` will be documented in this file.

## [0.8.1] - 2026-05-22

### Added

- `benchmarking.rs`: nuevo bloque `#[benchmark] fn claim_shielded_fees()` — primer weight real medido (~690 µs en CCX33). El placeholder anterior era 70 µs (10× subestimado).
- `operations/fees.rs`: guard `#[cfg(not(feature = "runtime-benchmarks"))]` en la llamada a `verify_value_proof` para evitar `CircuitNotFound` durante el benchmark (mismo patrón que `verify_proof` en pallet-zk-verifier).

### Changed

- Updated FRAME benchmark weights measured on Hetzner CCX33 (AMD EPYC-Milan, 8 vCPU dedicated, 32 GB RAM). Steps: `50`, Repeat: `20`. Covers: `shield`, `shield_batch`, `private_transfer`, `unshield`, `register_asset`, `verify_asset`, `unverify_asset`, `claim_shielded_fees`.

### Fixed

- `benchmarking.rs`: `private_transfer` and `unshield` benchmarks now use `T::Relayer::min_relay_fee().saturated_into()` as fee instead of `0`, which caused `FeeTooLow` errors and prevented weight generation for those extrinsics.

## [0.8.0] - 2026-05-14

### Added
Expand Down
2 changes: 1 addition & 1 deletion frame/shielded-pool/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "pallet-shielded-pool"
version = "0.8.0"
version = "0.8.1"
description = "Shielded pool pallet for private transactions using ZK proofs"
authors = ["Orbinum Team"]
license = "GPL-3.0-or-later"
Expand Down
33 changes: 33 additions & 0 deletions frame/shielded-pool/src/benchmarking.rs
Original file line number Diff line number Diff line change
Expand Up @@ -201,5 +201,38 @@ mod benchmarks {
unverify_asset(RawOrigin::Root, asset_id);
}

#[benchmark]
fn claim_shielded_fees() {
let (caller, asset_id) = setup_benchmark_env::<T>();
let amount: BalanceOf<T> = T::MinShieldAmount::get() * 10u32.into();
let amount_u128: u128 = amount.saturated_into();

// Acumular relay fees para el validator
T::Relayer::accumulate_relay_fee(&caller, asset_id, amount_u128);

let commitment = Commitment([0x11u8; 32]);

// public_signals layout (76 bytes): commitment(32) | value_le(8) | asset_id_le(4) | owner_hash(32)
let mut public_signals = vec![0u8; 76];
public_signals[..32].copy_from_slice(&commitment.0);
public_signals[32..40].copy_from_slice(&(amount_u128 as u64).to_le_bytes());
public_signals[40..44].copy_from_slice(&asset_id.to_le_bytes());

let proof = vec![0x01u8; 128];
let memo_bytes = vec![0u8; MAX_ENCRYPTED_MEMO_SIZE as usize];
let memo = FrameEncryptedMemo(memo_bytes.try_into().unwrap());

#[extrinsic_call]
claim_shielded_fees(
RawOrigin::Signed(caller),
commitment,
amount,
asset_id,
memo,
proof,
public_signals,
);
}

impl_benchmark_test_suite!(Pallet, crate::mock::new_test_ext(), crate::mock::Test,);
}
Loading
Loading