Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bench pallet: only require Hash instead of Block #3244

Merged
merged 11 commits into from
Feb 8, 2024

Conversation

ggwpez
Copy link
Member

@ggwpez ggwpez commented Feb 7, 2024

Preparation for #2664

Changes:

  • Only require Hash instead of Block for the benchmarking
  • Refactor DB types to do the same

Integration

This breaking change can easily be integrated into your node via:

- cmd.run::<Block, ()>(config)
+ cmd.run::<HashingFor<Block>, ()>(config)

Status: waiting for CI checks

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@ggwpez ggwpez added the T12-benchmarks This PR/Issue is related to benchmarking and weights. label Feb 7, 2024
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@ggwpez ggwpez changed the title Benchmarking: only require Hash instead of Block bench pallet: only require Hash instead of Block Feb 7, 2024
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@paritytech-cicd-pr
Copy link

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-clippy
Logs: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/5143341

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@ggwpez ggwpez marked this pull request as ready for review February 7, 2024 22:26
@ggwpez ggwpez requested a review from cheme February 7, 2024 22:26
Copy link
Contributor

@cheme cheme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good to me.

polkadot/cli/src/command.rs Show resolved Hide resolved
substrate/client/db/src/bench.rs Outdated Show resolved Hide resolved
Co-authored-by: cheme <emericchevalier.pro@gmail.com>
Copy link
Member

@bkchr bkchr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some nitpicks, otherwise looks good.

substrate/client/db/src/bench.rs Outdated Show resolved Hide resolved
prdoc/pr_3244.prdoc Outdated Show resolved Hide resolved
prdoc/pr_3244.prdoc Outdated Show resolved Hide resolved
ggwpez and others added 6 commits February 8, 2024 17:00
Co-authored-by: Bastian Köcher <git@kchr.de>
Co-authored-by: Bastian Köcher <git@kchr.de>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@ggwpez ggwpez enabled auto-merge February 8, 2024 16:15
@ggwpez ggwpez added this pull request to the merge queue Feb 8, 2024
Merged via the queue into master with commit c36c51c Feb 8, 2024
123 of 125 checks passed
@ggwpez ggwpez deleted the oty-bench-pallet-from-wasm branch February 8, 2024 18:06
bgallois pushed a commit to duniter/duniter-polkadot-sdk that referenced this pull request Mar 25, 2024
Preparation for paritytech#2664

Changes:
- Only require `Hash` instead of `Block` for the benchmarking
- Refactor DB types to do the same

## Integration

This breaking change can easily be integrated into your node via:  
```patch
- cmd.run::<Block, ()>(config)
+ cmd.run::<HashingFor<Block>, ()>(config)
```

Status: waiting for CI checks

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Bastian Köcher <git@kchr.de>
Co-authored-by: cheme <emericchevalier.pro@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T12-benchmarks This PR/Issue is related to benchmarking and weights.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants