-
Notifications
You must be signed in to change notification settings - Fork 19
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
Benchmark fixes #1971
Benchmark fixes #1971
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅ |
3cafc3c
to
0ec27a3
Compare
65b20f7
to
2d4b74e
Compare
d15cc94
to
5ae17eb
Compare
# Goal The goal of this PR is to create a new flow for benchmarks so that they are easier to run and do not require a separate github token. To test this must be in main as `workflow_dispatch` doesn't work without being in `main`, but here is a run that was triggered using defaults with a few other tweaks: https://github.com/frequency-chain/frequency/actions/runs/9174859575 # Discussion - The PR #1971 will remove the old system from the `.github/workflows/verify-pr-commit.yml` file so that only this one is used - Once PR #1971 is merged, I will also update the wiki with the new instructions
c7155b0
to
cca5142
Compare
@@ -750,114 +754,3 @@ jobs: | |||
echo "Actual genesis state: $actual_genesis_state" | |||
[ $actual_genesis_state = $expected_genesis_state ] || \ | |||
(echo "ERROR: The actual genesis state does not match the expected" && exit 1) | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also removed this from the required list for PRs.
{{#each benchmarks as |benchmark|}} | ||
{{#if (ne benchmark.base_calculated_proof_size "0")}} | ||
#[test] | ||
fn test_{{benchmark.name~}} () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make sure the benchmarks actually work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor updates from the polkadot-sdk patterns
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding common-runtime
under dev-dependencies to these so the weights tests work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am going ahead and merging the run with the tests.
@@ -224,3 +224,8 @@ then | |||
echo " " | |||
${BENCHMARK} overhead --wasm-execution=compiled --weight-path=runtime/common/src/weights --chain=dev --warmup=10 --repeat=100 --header="./HEADER-APACHE2" || exit_err | |||
fi | |||
|
|||
echo "Running tests..." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Run the tests after the benchmarks to make sure the benchmark generated code works.
@@ -1,6 +1,6 @@ | |||
// This file is part of Substrate. | |||
// This file is part of Frequency. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, always bugged me that it said Substrate. 🤓
@wilwade Could you please update the commit message to include a description of the issue? It seems to be missing from the ticket as well. Including this information would make it easier to review the PR. Additionally, as a friendly reminder, please keep PRs scoped to the issue at hand. It looks like there are some additional changes that might be out of scope for this particular fix. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great! 👍
@@ -1068,7 +1068,7 @@ impl pallet_proxy::Config for Runtime { | |||
type CallHasher = BlakeTwo256; | |||
type AnnouncementDepositBase = AnnouncementDepositBase; | |||
type AnnouncementDepositFactor = AnnouncementDepositFactor; | |||
type WeightInfo = weights::pallet_proxy::WeightInfo<Runtime>; | |||
type WeightInfo = weights::pallet_proxy::SubstrateWeight<Runtime>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix for the proxy_pallet
Updated the issue and the PR description to make it easier to understand why these were combined. (tldr: Couldn't run the benchmarks to verify the fix without greater changes) |
Thank you so much! |
Thanks for updating the Wiki. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Read through changes
🚢 it!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Read through the code, read through comments/questions...good to go
Goal
The goal of this PR is to fix an issue with running benchmarks and update our benchmarks with some tests.
Part of #1853
Issues
Discussion