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

upgrade polkadot sdk #208

Merged
merged 13 commits into from
Nov 27, 2024
Merged

upgrade polkadot sdk #208

merged 13 commits into from
Nov 27, 2024

Conversation

mattdean-digicatapult
Copy link
Contributor

@mattdean-digicatapult mattdean-digicatapult commented Nov 25, 2024

Pull Request

Checklist

  • Have you read Digital Catapult's Code of Conduct?
  • I have performed a self-review of my own code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have made corresponding changes to the documentation.
  • My changes generate no new warnings.
  • I have added tests that prove my fix is effective or that my feature works.
  • New and existing unit tests pass locally with my changes.

PR Type

Please delete options that are irrelevant.

  • Bug Fix
  • Chore
  • Feature
  • Documentation Update
  • Code style update (formatting, local variables)
  • Breaking Change (fix or feature that would cause existing functionality to change)

Linked tickets

https://digicatapult.atlassian.net/browse/SQNC-40

High level description

Upgrade polkadot-sdk to stable2409-2

Detailed description

This upgrade includes the following changes:

  • upgrades sdk components to stable2409-2 using https://github.com/paritytech/psvm
  • documents future upgrade procedure
  • adds storage version to all pallets that use storage. Explicitly labels those without as such
  • upgrades usage of the schedulerpallet to latest v3 api (the one we were using is deprecated)
  • adds a migration for the SymmetricKey pallet to update the schedule id. This was changed in a previous release but never upgraded in this pallet
  • renames sqnc-node-runtime to sqnc-runtime
  • explicitly labels our rust edition to match the polkadot sdk (2021)
  • updates to sqnc-node and sqnc-runtime in line with changes to solochain template at this version of the sdk
  • refactor weights for runtime
  • updates weights for all pallets (done but run locally. See SQNC-69)

I've also performed the following manual tests:

  • verified that migration works in a local dev environment
  • verified that code upgrade works for process validation pallet
  • verified that code upgrade works for utxo-nft pallet
  • verified that sqnc-matchmaker-api onchain tests pass with this node
  • verified that benchmarks compile and run

Describe alternatives you've considered

None

Operational impact

This update is a significant update to the Sequence node and runtime. Release will require first updating the node in produciton to this version and then the performing of a runtime upgrade. I would recommend a procudure like:

  1. Upgrade a single validator node instance and ensure it is both validating blocks and serving API requests from matchmaker
  2. Upgrade the remaining nodes ensuring the network remains healthy
  3. Perform the runtime upgrade using the technical committee

Note step 3 is irreversible except by rolling back the PVs to a backup.

Additional context

N/A

Copy link

This PR updates the following pallets - they may also require updates to their extrinsic weights:
process-validation symmetric-key utxo-nft

For the author and any reviewers:

  • consider whether the changes could significantly affect the weight of any extrinsics
  • consider whether benchmarks need updating to correctly cover weight variations over inputs

For a guide on running benchmarks to update weights see calculating weights

@mattdean-digicatapult mattdean-digicatapult marked this pull request as ready for review November 26, 2024 14:09
@mattdean-digicatapult mattdean-digicatapult requested a review from a team as a code owner November 26, 2024 14:09
Copy link
Contributor

@Ellenn-A Ellenn-A left a comment

Choose a reason for hiding this comment

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

need to check version that is deployed is 1120 version

@mattdean-digicatapult
Copy link
Contributor Author

need to check version that is deployed is 1120 version

I've verified that the deployed version for prod is 1120 and the pallet-utxo-nft has been renamed there as expected

@mattdean-digicatapult mattdean-digicatapult merged commit a5649f1 into main Nov 27, 2024
8 checks passed
@mattdean-digicatapult mattdean-digicatapult deleted the chore/upgrade-polkadot-sdk branch November 27, 2024 08:45
@mattdean-digicatapult mattdean-digicatapult mentioned this pull request Nov 27, 2024
13 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants