-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Remove Offence delay #8414
Remove Offence delay #8414
Conversation
One question, the only safe and deterministic way to remove the |
Sorry, don't get what you mean here? |
All unit tests passed 🎉 The only thing that is missing is create a test that verifies if all offences has been resubmitted after on_runtime_upgrade |
Yeah, while generally it is a rare scenario, worth having a test for it. |
Ok all good, but I don't have permission to add the labels and make CI happy. |
@thiolliere good catch, |
Now I'm working on the companion PR |
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.
lgtm
bot merge |
Error: Error getting organization membership: Status code: 404 Not Found |
@Lohann will have Kian merge this when he wakes up and if he is happy |
@shawntabrizi sounds good! thx for your patience reviewing this PR 🙏 Btw the Companion section of CONTRIBUTING.adoc#updating-polkadot-as-well needs to be updated, using For create the companion PR I used diener instead, which is not documented but I've found it in the check_polkadot_companion_build.sh script.
|
This works for me last I tried. What did you see was the issue when you tried it? |
Will run again, one minute |
My
Output of
|
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.
Thanks!
bot merge |
Waiting for commit status. |
* Removed can_report api from OnOffenceHandler * Removed DeferredOffences and create a storage migration * Removed missing comments * Mock set_deferred_offences and deferred_offences methods * OnOffenceHandler::on_offence always succeed * Fix benchmark tests * Fix runtime-benchmark cfg methods * Removed 'applied' attribute from Offence event * refactor deprecated deferred offences getter * Validate if offences are submited after on_runtime_upgrade * update changelog * Remove empty lines * Fix remove_deferred_storage weights * Remove Offence::on_runtime_upgrade benchmark * Revert CHANGELOG.md update * Deprecate DeferredOffenceOf type * Update copyright Co-authored-by: Kian Paimani <[email protected]> * Add migration logs Co-authored-by: Kian Paimani <[email protected]> * Fix migration log * Remove unused import * Add migration tests * rustfmt * use generate_storage_alias! macro * Refactor should_resubmit_deferred_offences test * Replace spaces by tabs * Refactor should_resubmit_deferred_offences test * Removed WeightSoftLimit * Removed WeightSoftLimit from tests and mocks * Remove unused imports * Apply suggestions from code review Co-authored-by: Kian Paimani <[email protected]>
* Removed can_report api from OnOffenceHandler * Removed DeferredOffences and create a storage migration * Removed missing comments * Mock set_deferred_offences and deferred_offences methods * OnOffenceHandler::on_offence always succeed * Fix benchmark tests * Fix runtime-benchmark cfg methods * Removed 'applied' attribute from Offence event * refactor deprecated deferred offences getter * Validate if offences are submited after on_runtime_upgrade * update changelog * Remove empty lines * Fix remove_deferred_storage weights * Remove Offence::on_runtime_upgrade benchmark * Revert CHANGELOG.md update * Deprecate DeferredOffenceOf type * Update copyright Co-authored-by: Kian Paimani <[email protected]> * Add migration logs Co-authored-by: Kian Paimani <[email protected]> * Fix migration log * Remove unused import * Add migration tests * rustfmt * use generate_storage_alias! macro * Refactor should_resubmit_deferred_offences test * Replace spaces by tabs * Refactor should_resubmit_deferred_offences test * Removed WeightSoftLimit * Removed WeightSoftLimit from tests and mocks * Remove unused imports * Apply suggestions from code review Co-authored-by: Kian Paimani <[email protected]>
Description
An offence can and should be immediately processed by the staking pallet.
Fixes #8343
Checklist:
can_report
API fromOnOffenceHandler
DeferredOffences
storage from offences palleton_runtime_upgrade
hookContext
Due to some technical circumstances the Offence delay has been introduced here #4517
There's a good discussion about how to properly migrate storages here: #8243
polkadot companion: paritytech/polkadot#2966